Remove zsh check from vim window flag
Make using the `@vim$TMUX_PANE` window flag much more robust by unsetting it every time the zsh prompt is drawn and setting it again using a `FocusGained` `autocmd` in vim. This removes the need for the hacky check for zsh in the conditional defined in the `in_vim` variable.
This commit is contained in:
parent
43ce79c8c3
commit
b5526ca42b
@ -62,8 +62,7 @@ bind '"' split-window -c '#{pane_current_path}'
|
||||
bind '%' split-window -h -c '#{pane_current_path}'
|
||||
|
||||
# Integrate pane selection with vim
|
||||
in_vim='tmux show-window-options | grep -q "@vim#{pane_id}" && \
|
||||
[ "#{pane_current_command}" != "zsh" ]'
|
||||
in_vim='tmux show-window-options | grep -q "@vim#{pane_id}"'
|
||||
bind -n C-h if $in_vim 'send-keys C-h' 'select-pane -L'
|
||||
bind -n C-j if $in_vim 'send-keys C-j' 'select-pane -D'
|
||||
bind -n C-k if $in_vim 'send-keys C-k' 'select-pane -U'
|
||||
|
Loading…
x
Reference in New Issue
Block a user