diff --git a/plugins/tmux/tmux.extra.conf b/plugins/tmux/tmux.extra.conf index 3420d19d4..c4aaad0b0 100644 --- a/plugins/tmux/tmux.extra.conf +++ b/plugins/tmux/tmux.extra.conf @@ -1,2 +1,2 @@ set -g default-terminal $ZSH_TMUX_TERM -source $ZSH_TMUX_CONFIG \ No newline at end of file +source-file $ZSH_TMUX_CONFIG \ No newline at end of file diff --git a/plugins/tmux/tmux.plugin.zsh b/plugins/tmux/tmux.plugin.zsh index d7b299690..5b5d1b1ba 100644 --- a/plugins/tmux/tmux.plugin.zsh +++ b/plugins/tmux/tmux.plugin.zsh @@ -67,9 +67,12 @@ function _zsh_tmux_plugin_run() { # If failed, just run tmux, fixing the TERM variable if requested. if [[ $? -ne 0 ]]; then - [[ "$ZSH_TMUX_FIXTERM" == "true" ]] && tmux_cmd+=(-f "$_ZSH_TMUX_FIXED_CONFIG") || \ - [[ -e "$ZSH_TMUX_CONFIG" ]] && tmux_cmd+=(-f "$ZSH_TMUX_CONFIG") - $tmux_cmd new-session + if [[ "$ZSH_TMUX_FIXTERM" == "true" ]]; then + tmux_cmd+=(-f "$_ZSH_TMUX_FIXED_CONFIG") + elif [[ -e "$ZSH_TMUX_CONFIG" ]]; then + tmux_cmd+=(-f "$ZSH_TMUX_CONFIG") + fi + $tmux_cmd new-session fi if [[ "$ZSH_TMUX_AUTOQUIT" == "true" ]]; then