Fix experssion to check whether zsh is running inside vim or emacs

This commit is contained in:
15cm 2017-04-28 12:50:40 +08:00
commit a8cf80326d

View file

@ -84,7 +84,7 @@ if which tmux &> /dev/null
alias tmux=_zsh_tmux_plugin_run alias tmux=_zsh_tmux_plugin_run
# Autostart if not already in tmux and enabled. # Autostart if not already in tmux and enabled.
if [[ ! -n "$TMUX" && "$ZSH_TMUX_AUTOSTART" == "true" && ( -n "$INSIDE_EMACS" || -n "$EMACS" || -n "$VIM" ) ]] if [[ ! -n "$TMUX" && "$ZSH_TMUX_AUTOSTART" == "true" && ! ( -n "$INSIDE_EMACS" || -n "$EMACS" || -n "$VIM" ) ]]
then then
# Actually don't autostart if we already did and multiple autostarts are disabled. # Actually don't autostart if we already did and multiple autostarts are disabled.
if [[ "$ZSH_TMUX_AUTOSTART_ONCE" == "false" || "$ZSH_TMUX_AUTOSTARTED" != "true" ]] if [[ "$ZSH_TMUX_AUTOSTART_ONCE" == "false" || "$ZSH_TMUX_AUTOSTARTED" != "true" ]]