From 3b44361df3ede6208faa6fc97d584d33889dedf5 Mon Sep 17 00:00:00 2001 From: David Runge Date: Tue, 17 Jun 2014 16:04:55 +0200 Subject: Adding bindings for vi-copy mode in tmux --- .tmux.conf | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/.tmux.conf b/.tmux.conf index 6fefcb7..586539c 100644 --- a/.tmux.conf +++ b/.tmux.conf @@ -62,7 +62,6 @@ setw -g mode-mouse on - # Keep your finger on ctrl, or don't bind-key ^D detach-client @@ -73,6 +72,14 @@ set -g status-keys vi # Use vi keybindings in copy and choice modes setw -g mode-keys vi +# v and y like vi in copy-mode +bind-key -t vi-copy 'v' begin-selection +bind-key -t vi-copy 'y' copy-selection +# clipboard settings +set -s set-clipboard on +bind-key C-p run "xclip -o | tmux load-buffer - ; tmux paste-buffer" +bind-key C-y run "tmux save-buffer - | xclip -i" + # set first window to index 1 (not 0) to map more to the keyboard layout... set -g base-index 1 -- cgit v1.2.3-70-g09d2