← Back to home

Linux

xclip

Copy text directly from the terminal to the clipboard:

echo "Your text here" | xclip -sel clip

Copy a file’s contents to the clipboard:

xclip -in textfile.txt -sel clip