xclip is a command line interface to the X11 clipboard. It can also be used for copying files, as an alternative to sftp/scp, thus avoiding password prompts when X11 forwarding has already been setup.

learn more… | top users | synonyms

9
votes
1answer
81 views

Is it possible to know the source (application) of the clipboard?

I've noticed that sometimes clipboard contents become unavailable if the source application (where the content was copied from) is closed. This leads me to wonder if it's possible to know what the ...
1
vote
1answer
29 views

Is there a way to replace the currently selected text on X11?

I stumbled across xclip which gives you access to the text you have selected on your active window. I've been thinking if there was a way to alter such text. The workflow I have in mind is the ...
10
votes
2answers
6k views

Use system clipboard in vi-copy mode in tmux

I'm running tmux 1.6 and I'm trying to configure it to use vi-style keybindings as well as use the system clipboard when copying in interactive mode: set-window-option -g mode-keys vi bind-key -t ...
1
vote
0answers
110 views

xclip does not change the clipboard content

I'm trying to give the following command: echo "hi" | xclip -selection c This doesn't work? It has worked in the past, but never consistently. I also tried echo "hi" | xclip -selection primary ...
4
votes
1answer
448 views

Copy markdown input to the clipboard as rich text

I'm about to get involved in some collaborative prose writing with a friend of mine via email. As a regular person, he will of course be using MS Word document formats; as a massive nerd, I prefer to ...
5
votes
2answers
422 views

How to target multiple selections with xclip

When copying text to the clipboard, xclip provides several selection targets: -selection specify which X selection to use, options are: "primary" to use XA_PRIMARY (default), ...
61
votes
13answers
39k views

Getting tmux to copy a buffer to the clipboard

I am trying to figure out a decent way to copy what I have in a tmux buffer into my clipboard. I have tried a couple of different things like bind-key p select-pane -t 2 \; split-window 'xsel -i ...