You are not logged in.

#1 2015-11-02 08:45:15

gkjarch
Member
Registered: 2013-03-31
Posts: 22

tmux works with xclip

I have read https://wiki.archlinux.org/index.php/Tm … ntegration. I google something and I figure out how tmux works with xclip.
Here is the code:

# VI mode
setw -g mode-keys vi
bind -n M-u copy-mode
bind -t vi-copy 'v' begin-selection
bind -t vi-copy 'y' copy-selection

# copy tmux paste buffer to CLIPBOARD
bind -n C-x run -b "tmux show-buffer | xclip -i -selection clipboard"

# copy CLIPBOARD to tmux paste buffer and paste tmux paste buffer
bind -n C-v run "tmux set-buffer -- \"$(xclip -o -selection clipboard)\"; tmux paste-buffer"

The config code only tested with xterm.

Offline

Board footer

Powered by FluxBB