how to pipe Wayland clipboard into an X vnc session clipboard over ssh
1
vote
0
answers
673
views
I am using Wayland on Arch, and am
ssh
ed into a debian server which uses X11. I have a vnc session running over that ssh connection. I would like to take a string that I have stored in my Wayland clipboard, and put it into the X clipboard on the server so that I can use that string with ctrl+v
in the vnc session.
I thought this would be as simple as opening a terminal emulator via vnc, checking the $DISPLAY
variable there, then using echo "string" | xclip -d ':display' -selection clipboard
in my ssh session (I can just use ctrl+shift+v in my local terminal emulator to paste the string into the command). However, that does not work. It seems to copy fine, but then clipboard -o -d ':display' -selection clipboard
shows the previous thing in the clipboard, and not the thing I just tried to copy.
So far, I've been doing echo "string" > tmpfile
, then opening the file in a text editor in the vnc session, and copying it from there. However, that is clunky.
Obviously, the ideal solution would be to take the time to reconfigure my server so that I can access it remotely in a more sensible manner, but that would take time. I'd like a solution I can use in the meantime, and I'd like to understand why the above method doesn't work like I expected.
Asked by mangoduck
(53 rep)
Jun 22, 2022, 07:32 PM