Closed jaehyung-ca closed 3 years ago
Thanks for the encouragement!
You can do the same kind of thing with copytk using the @copytk-copy-command
option; it just defaults to tmux load-buffer -
, but can also be set to use xclip
in the same way. If you'd like to send it to both xclip
and to a tmux buffer, it just takes a short shell script to read stdin and invoke both. A little while back I wrote a blog post about multi-way synchronization, but it may be more than what you're looking for.
I tried a few things, but nothing worked.
echo 'test' | xclip -selection c
echo 'test' | tmux load-buffer - ; tmux save-buffer - | xclip -selection c
both work, but
set -g @copytk-copy-command "xclip -selection c"
set -g @copytk-copy-command "tmux load-buffer -; tmux save-buffer - | xclip -selection c"
do not work.
I logged every step inside the runshellcommand and the program is stuck in the
recvstdout, _ = proc.communicate(input=sendstdin)
So, I have no idea.
Fixed by PR #6 . Thanks jaehyung-ca!
Hi there,
First, thank you for the awesome plugin.
Is there a way to copy Tmux buffer to a clipboard with your plugin? I'm using Tmux v3.0a on Ubuntu 20.04.
I could do it on Tmux copy-mode by set .tmux.conf like this.
bind -T copy-mode-vi y send-keys -X copy-pipe-and-cancel 'xclip -in -selection clipboard'
But it does not work with your plugin.