lemonade-command / lemonade

Lemonade is a remote utility tool. (copy, paste and open browser) over TCP.
MIT License
627 stars 54 forks source link

Support for Wayland? #44

Open IamNoRobot opened 1 year ago

IamNoRobot commented 1 year ago

Hi, I'm using Linux (KDE Neon 22.04) on my desktop with Wayland and Debian Bullseye on my (headless) little Homeserver. Sharing the Clipboard works MARVELOUS on a Xorg Session. Absolutely no Issues.

No such luck on Wayland tough. When I have lemonade server running on my Desktop, it'll still print lines, when trying to do something on the Client with the Clipboard, but there is no exchange between the boards.

I suppose lemonade is using xsel or xclip on the server side? This would explain why it ain't working with Wayland. Is there a way around that? Or am I overlooking something very obvious and just make a fool out of myself?

Thanks for any help.

(Ps: Thanks for your work! I really appreciate it!)

leafee98 commented 1 year ago

Wayland is supported, but you need to install wl-clipboard first.

toantk238 commented 1 year ago

I confirm that Lemonade is working on Wayland. I'm using EndeavorOS with Gnome3 + Wayland.

andrewjwaggoner commented 4 months ago

This issue can be closed.

hholst80 commented 3 months ago

If you don't have that you might write your own lightweight wl.

#!/bin/bash
case $1 in
  server)
    socat TCP-LISTEN:2489,FORK SYSTEM:"wl-copy -n" &
    socat TCP-LISTEN:2490,FORK SYSTEM:"wl-paste -n" &
    wait
    kill %1 %2
    ;;
  copy)
    shift 1
    if [ $# -eq 0 ] 
    then
      nc -c 127.0.0.1 2489
    else
      echo "$@" | nc -c 127.0.0.1 2489
    fi
    ;;
  paste)
    nc -c 127.0.0.1 2490
    ;;
esac