Hello,
I'd like to write the content of a .txt file to the X11+KDE clipboard,
in order to do that I defined an "alias":
~$ alias toclip="qdbus6 org.kde.klipper /klipper
org.kde.klipper.klipper.setClipboardContents"
~$ cat b.txt
someText
The following command return error:
~$ cat b.txt | toclip
Error: org.freedesktop.DBus.Error.UnknownMethod
No such method 'setClipboardContents' in interface
'org.kde.klipper.klipper' at object path '/klipper' (signature '')
The following command works:
~$ toclip "$(cat b.txt)"
Is there a way to rearrange the "toclip" alias in order that it works
using a pipe? Thus:
~$ cat b.txt | toclip
Please don't tell me to use "xclipboard" or "xset" I just want to use
the DBus channel.
Thank in advance, kind regards
--
Franco Martelli