From 606f430950f2f89039634138d37ec81593f2f6bb Mon Sep 17 00:00:00 2001 From: Alpha Chen Date: Sun, 21 May 2017 11:35:46 -0700 Subject: [PATCH] [tmux] automatically copy to pasteboard --- .tmux.conf | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/.tmux.conf b/.tmux.conf index b21e4d2..803f259 100644 --- a/.tmux.conf +++ b/.tmux.conf @@ -19,8 +19,11 @@ set-option -g automatic-rename on set-window-option -g mouse off # copy and paste -bind -t vi-copy 'v' begin-selection -bind -t vi-copy 'y' copy-selection +set-option mode-keys vi +bind-key -T copy-mode-vi 'v' send -X begin-selection +bind-key -T copy-mode-vi 'V' send -X select-line +bind-key -T copy-mode-vi 'r' send -X rectangle-toggle +bind-key -T copy-mode-vi 'y' send -X copy-pipe-and-cancel "reattach-to-user-namespace pbcopy" ## etc set-window-option -g mode-keys vi