Writing to clipboard in a command line flatpak.
Emil Johansson
emil.sweden at gmail.com
Sun Feb 7 12:26:32 UTC 2021
Hey,
I am trying to make a flatpak version of my command line application
https://github.com/emiljoha/mpw. I have gotten most of the dependencies in
order but I have not been able to figure out how to write to the clipboard.
I have managed to bundle wl-clipboard but it says it cannot connect to a
wayland server. Looking in the source code of wl-clipboard it gets NULL
back from wl_display_connect. From the documentation I can find
https://manpages.debian.org/experimental/libwayland-doc/wl_display_connect.3.en.html
> *wl_display_connect* connects to a Wayland socket that was previously
opened by a Wayland server. The server socket must be placed in
*XDG_RUNTIME_DIR* when *WAYLAND_DISPLAY* (or *name*, see below) is a simple
name, for this function to find it. The server socket is also allowed to
exist at an arbitrary path
wl-copy.c call the function with NULL as the name.
I have in my manifest.
finish-args:
--socket=fallback-x11
--share=ipc
More details and the code of my attempt can be found in the PR
https://github.com/emiljoha/mpw/pull/21
Thanks
Emil
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/flatpak/attachments/20210207/19cb4697/attachment.htm>
More information about the Flatpak
mailing list