summaryrefslogtreecommitdiffstats
path: root/.tmux.conf
diff options
context:
space:
mode:
authorTyler Davis <tydavis@gmail.com>2020-09-22 12:05:50 -0700
committerTyler Davis <tydavis@gmail.com>2020-09-22 12:05:50 -0700
commit855e7bade9ac7f8bdccdb3e06cf91907721899cf (patch)
tree01fb509c56a4535c8ee4d3cbb2ef68ca81de37ee /.tmux.conf
parent1d48eac8dfe0e1664803059b246d0f6c46fe6760 (diff)
downloaddotfiles-855e7bade9ac7f8bdccdb3e06cf91907721899cf.tar.gz
dotfiles-855e7bade9ac7f8bdccdb3e06cf91907721899cf.zip
tmux: add vim keys
Diffstat (limited to '.tmux.conf')
-rw-r--r--.tmux.conf30
1 files changed, 30 insertions, 0 deletions
diff --git a/.tmux.conf b/.tmux.conf
index 93fe802..e928484 100644
--- a/.tmux.conf
+++ b/.tmux.conf
@@ -5,6 +5,11 @@ set -sg escape-time 10
set -g default-terminal "tmux-256color"
set -ga terminal-overrides ",xterm-termite:Tc"
+set -g base-index 1
+setw -g pane-base-index 1
+
+### VIM RELEVANT KEYBINDINGS
+
# VI keybindings
set -g mode-keys vi
set-window-option -g mode-keys vi
@@ -14,3 +19,28 @@ bind P paste-buffer
bind-key -T copy-mode-vi v send-keys -X begin-selection
bind-key -T copy-mode-vi y send-keys -X copy-selection
bind-key -T copy-mode-vi r send-keys -X rectangle-toggle
+
+#Mouse works as expected
+set -g mouse on
+
+setw -g monitor-activity on
+set -g visual-activity on
+
+set -g mode-keys vi
+set -g history-limit 10000
+
+# moving between panes with vim movement keys
+bind h select-pane -L
+bind j select-pane -D
+bind k select-pane -U
+bind l select-pane -R
+
+# moving between windows with vim movement keys
+bind -r C-h select-window -t :-
+bind -r C-l select-window -t :+
+
+# resize panes with vim movement keys
+bind -r H resize-pane -L 5
+bind -r J resize-pane -D 5
+bind -r K resize-pane -U 5
+bind -r L resize-pane -R 5