Browse Source

[tmux] vim-style copy paste with copy to system clipboard.

master
Fredrik Ekre 5 years ago
parent
commit
7a07883550
  1. 10
      .tmux.conf

10
.tmux.conf

@ -18,6 +18,16 @@ bind-key -r l select-pane -R @@ -18,6 +18,16 @@ bind-key -r l select-pane -R
# vim mode keys in copy-mode
set-window-option -g mode-keys vi
# start selection with v and end with y
## tmux <= 2.3
bind-key -t vi-copy 'v' begin-selection
bind-key -t vi-copy 'y' copy-selection
## tmux > 2.3
# bind-key -T copy-mode-vi v send-keys -X begin-selection
# bind-key -T copy-mode-vi y send-keys -X copy-selection
# use system clipboard
bind -t vi-copy y copy-pipe "xclip -sel clip -i"
# bind-key -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -sel clip -i'
# Faster repeat time
set-option -g repeat-time 300

Loading…
Cancel
Save