how to make tmux both copy-pipe and clear selection ?

428 views
Skip to first unread message

Shiyao Ma

unread,
Mar 23, 2017, 6:40:29 AM3/23/17
to tmux-...@googlegroups.com
Hi,

I'd like to tmux run the copy-pipe and then clear -selection.

The following binding fails.
tmux bind-key -Tcopy-mode-vi y send -X copy-pipe "nc localhost 8377" clear-selection
failed.


Nicholas Marriott

unread,
Mar 23, 2017, 7:30:08 AM3/23/17
to Shiyao Ma, tmux-...@googlegroups.com
send -X copy-pipe "abc" \; send -X clear-selection
> --
> You received this message because you are subscribed to the Google Groups
> "tmux-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to tmux-users+...@googlegroups.com.
> To post to this group, send email to tmux-...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

Shiyao Ma

unread,
Mar 23, 2017, 7:33:10 AM3/23/17
to Nicholas Marriott, tmux-...@googlegroups.com
Here's the error I got:


❯❯❯ tmux bind-key -Tcopy-mode-vi y send -X copy-pipe "nc localhost 8377" \; send -X clear-selection
not in a mode



Nicholas Marriott

unread,
Mar 23, 2017, 7:50:49 AM3/23/17
to Shiyao Ma, tmux-...@googlegroups.com
Try \\; instead of \;



On Thu, Mar 23, 2017 at 07:31:55PM +0800, Shiyao Ma wrote:
> Here's the error I got:
> a*-a*-a*- tmux bind-key -Tcopy-mode-vi y send -X copy-pipe "nc localhost

Shiyao Ma

unread,
Mar 23, 2017, 8:00:11 AM3/23/17
to Nicholas Marriott, tmux-...@googlegroups.com
Thanks. quoting '\;' works.
Reply all
Reply to author
Forward
0 new messages