the-way icon indicating copy to clipboard operation
the-way copied to clipboard

Adds xsel support

Open jgarte opened this issue 4 years ago • 3 comments

Hi, this is a WIP pr for adding xsel support as a configuration option.

Any help or guidance is much appreciated.

jgarte avatar Oct 01 '21 04:10 jgarte

@jgarte I guess the expected behavior is to check if xclip is in the PATH otherwise fall back to xsel? You could use the which crate to do this or traverse the PATH and check (e.g this SO answer)

Ninjani avatar Oct 26 '21 13:10 Ninjani

@jgarte I guess the expected behavior is to check if xclip is in the PATH otherwise fall back to xsel? You could use the which crate to do this or traverse the PATH and check (e.g this SO answer)

Cool, I'll check that out.

This is how emacs-xclip does it:

https://git.savannah.gnu.org/gitweb/?p=emacs/elpa.git;a=blob;f=xclip.el;h=71efda328c60649ac63b6140a291e92bddf428e9;hb=refs/heads/externals/xclip#l131

Sounds like the which crate might be the way to go. Thanks for sharing.

jgarte avatar Oct 26 '21 18:10 jgarte

It would be really cool if those two constants will be available for override in config. In my case I need wl-copy on Wayland.

ony avatar Dec 05 '21 00:12 ony