From 41f7f0b66a6ab9f6bce258d4eeb3bb6a7aaca313 Mon Sep 17 00:00:00 2001 From: Egor Tensin Date: Fri, 18 Dec 2020 04:55:05 +0300 Subject: tmux: revise key bindings --- %HOME%/.tmux.conf | 16 +++++++--------- 1 file changed, 7 insertions(+), 9 deletions(-) diff --git a/%HOME%/.tmux.conf b/%HOME%/.tmux.conf index 74f3c32..297354a 100644 --- a/%HOME%/.tmux.conf +++ b/%HOME%/.tmux.conf @@ -8,7 +8,7 @@ # C-b is hella uncomfortable to press. unbind C-b set -g prefix C-j -bind -n C-a send-prefix +bind -n M-j send-prefix # Numbering starts at 1 instead of 0. set -g base-index 1 @@ -77,10 +77,10 @@ bind -r C-k select-pane -U bind -r C-l select-pane -R # Switch between windows. Ctrl must be released. -bind h next-window -bind l previous-window -#bind h select-window -t :- -#bind l select-window -t :+ +#bind h next-window +#bind l previous-window +bind h select-window -t :- +bind l select-window -t :+ # Copy mode bindings # ------------------ @@ -107,8 +107,7 @@ if-shell 'uname | grep -q -F CYGWIN' { bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel 'cat > /dev/clipboard' bind-key -T root MouseDown2Pane run 'cat /dev/clipboard | tmux load-buffer - && tmux paste-buffer' - unbind p - bind-key p run 'cat /dev/clipboard | tmux load-buffer - && tmux paste-buffer' + bind-key ] run 'cat /dev/clipboard | tmux load-buffer - && tmux paste-buffer' } # The simple `xsel -i --clipboard` doesn't work, but `xsel -i -p && xsel -o -p @@ -124,8 +123,7 @@ if-shell 'uname | grep -q -F Linux && which xsel' { bind-key -T copy-mode-vi MouseDragEnd1Pane send-keys -X copy-pipe-and-cancel 'xsel -i -p && xsel -o -p | xsel -i -b' bind-key -T root MouseDown2Pane run 'xsel -o | tmux load-buffer - && tmux paste-buffer' - unbind p - bind-key p run 'xsel -o | tmux load-buffer - && tmux paste-buffer' + bind-key ] run 'xsel -o | tmux load-buffer - && tmux paste-buffer' } # Appearance -- cgit v1.2.3