Advertisement
Guest User

Untitled

a guest
Mar 24th, 2017
72
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.65 KB | None | 0 0
  1. set -g default-terminal "screen-256color"
  2. set -g mouse on
  3. set -sg escape-time 0
  4.  
  5. # Smart pane switching with awareness of Vim splits.
  6. # See: https://github.com/christoomey/vim-tmux-navigator
  7. is_vim="ps -o state= -o comm= -t '#{pane_tty}' \
  8. | grep -iqE '^[^TXZ ]+ +(\\S+\\/)?g?(view|n?vim?x?)(diff)?$'"
  9. bind-key -n C-h if-shell "$is_vim" "send-keys C-h" "select-pane -L"
  10. bind-key -n C-j if-shell "$is_vim" "send-keys C-j" "select-pane -D"
  11. bind-key -n C-k if-shell "$is_vim" "send-keys C-k" "select-pane -U"
  12. bind-key -n C-l if-shell "$is_vim" "send-keys C-l" "select-pane -R"
  13. bind-key -n C-\ if-shell "$is_vim" "send-keys C-\\" "select-pane -l"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement