Xfce Forum

Sub domains
 

You are not logged in.

#1 2021-01-22 21:08:02

Friedrich
Member
Registered: 2016-09-18
Posts: 77

Copy text to clipboard from shell script

Hi

how can i copy text to the xfce-clipboard that was created with a shell script? I know there are tools like xclip but they need there own command to paste it somewhere. To use the text in the system the best way would be to copy it to the xfce-clipboard (xfce4-clipman).

friedrich

Offline

#2 2021-01-23 00:00:58

ToZ
Moderator
From: Canada
Registered: 2011-06-02
Posts: 7,415

Re: Copy text to clipboard from shell script

Pipe your shell script output to xclip and specify the clipboard as the destination. Example:

echo "test" | xclip -selection clipboard

Offline

#3 2021-01-23 07:18:36

Friedrich
Member
Registered: 2016-09-18
Posts: 77

Re: Copy text to clipboard from shell script

Thanks.

Offline

Board footer

Powered by FluxBB