From fc3222197acafba3044ea8138edaf7b701fa5565 Mon Sep 17 00:00:00 2001 From: humphreylin Date: Tue, 13 Aug 2019 03:17:48 +0000 Subject: set vim mode on tmux and add some key binding in vim --- .tmux.conf | 7 +++++++ 1 file changed, 7 insertions(+) (limited to '.tmux.conf') diff --git a/.tmux.conf b/.tmux.conf index 760637a..b2e3fff 100644 --- a/.tmux.conf +++ b/.tmux.conf @@ -2,6 +2,13 @@ unbind ^b set -g prefix 'M-`' +# vim mode +setw -g mode-keys vi + +# copy and paste like vim +bind -T copy-mode-vi 'v' send -X begin-selection +bind -T copy-mode-vi 'y' send -X copy-pipe-and-cancel "reattach-to-user-namespace pbcopy" + # swtich between pane bind h select-pane -L bind j select-pane -D -- cgit v1.2.3