tmux 复制粘贴

tmux版本(tmux 2.3):linux

 $tmux -V

 

要想让tmux和系统剪贴板之间互相复制粘贴,在linux中须要先安装 xclip:缓存

sudo apt-get install xclip

 而后在 .tmux.conf 文件中:bash

# 把当前缓存区的内容复制到系统剪贴板
bind -t vi-copy y copy-pipe "xclip -sel clip -i" 

# 把系统剪贴板内容复制到tmux
bind P run "tmux set-buffer \"$(xclip -o)\"; tmux paste-buffer"
相关文章
相关标签/搜索