From 08a3d8ce3b694004290e9fdf60ba4913a570368d Mon Sep 17 00:00:00 2001 From: Ernest Wong Date: Sun, 17 Sep 2017 16:52:44 +1200 Subject: [PATCH] Improve tmux copy-mode bindings... 1. reuse original enter-copy-mode binding [ 2. add stop-selection binding Q 3. add copy-to-windows binding Y --- .tmux.conf | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.tmux.conf b/.tmux.conf index d896d24..aaec86e 100644 --- a/.tmux.conf +++ b/.tmux.conf @@ -5,18 +5,18 @@ set -g @plugin 'tmux-plugins/tmux-resurrect' # Key bindings - tmux clipboard buffer set-window-option -g mode-keys vi -unbind [ -bind Escape copy-mode bind P paste-buffer bind -T copy-mode-vi v send-keys -X begin-selection bind -T copy-mode-vi y send-keys -X copy-selection bind -T copy-mode-vi r send-keys -X rectangle-toggle +bind -T copy-mode-vi Q send-keys -X stop-selection -# Key bindings - Paste from Windows clipboard +# Key bindings - Windows clipboard bind C-p run "\ paste.exe \ | tmux load-buffer -b windows-paste-buffer - \ && tmux paste-buffer -b windows-paste-buffer" +bind -T copy-mode-vi Y send-keys -X copy-pipe "clip.exe" # True color! set-option -ga terminal-overrides ",xterm-256color:Tc"