From tino.calancha at gmail.com Wed May 3 06:26:33 2023 From: tino.calancha at gmail.com (Tino Calancha) Date: Wed, 3 May 2023 08:26:33 +0200 (CEST) Subject: [PATCH] emacs: Drop dependency on s library In-Reply-To: <20230425231905.32488-1-mekeor@posteo.de> References: <20230425231905.32488-1-mekeor@posteo.de> Message-ID: On Tue, 25 Apr 2023, Mekeor Melire wrote: > We can safely remove it since we are not using it. I have merged your patch. Thank you! Tino From doug.hs at proton.me Sun May 14 06:05:58 2023 From: doug.hs at proton.me (Douglas Silva) Date: Sun, 14 May 2023 06:05:58 +0000 Subject: [PATCH] Add support for Windows clipboard (WSL) In-Reply-To: References: Message-ID: <9GHs7xPnGVutXHBRn3T2KGS5K2BWHYsOkjLh8OY8koDlVwp8P3gPeCTrad1AUo0BBhOvo963ltt8fpP9S4DWt3Rdw7B4_Co6Eq6C53yrNRk=@proton.me> Windows 11 is now exposing your display to WSL. This means xclip and wl-clipboard will no longer fail with an error. pass will attempt to use wl-clipboard, because the variable $WAYLAND_DISPLAY is now set ("wayland-0"). This Wayland display mirrors your host [Windows] display. I've tested it and the clip function works, including the cleanup after 45 seconds. ------- Original Message ------- Em s?bado, 15 de outubro de 2022 ?s 8:59 PM, Douglas Silva escreveu: > This makes the -c (copy to clipboard) option work on WSL, by using the clip.exe command if it's available. I picked $WSL_DISTRO_NAME to test for it. > > Note that I didn't set "paste_cmd" or "display_name". I couldn't find any paste command for Windows, and I don't understand what they're used for. > > --- > src/password-store.sh | 4 +++- > 1 file changed, 3 insertions(+), 1 deletion(-) > > diff --git a/src/password-store.sh b/src/password-store.sh > index 22e818f..7f64b68 100755 > --- a/src/password-store.sh > +++ b/src/password-store.sh > @@ -155,7 +155,9 @@ check_sneaky_paths() { > # > > clip() { > - if [[ -n $WAYLAND_DISPLAY ]] && command -v wl-copy &> /dev/null; then > > + if [[ -n $WSL_DISTRO_NAME ]] && command -v clip.exe &> /dev/null; then > > + local copy_cmd=( clip.exe ) > + elif [[ -n $WAYLAND_DISPLAY ]] && command -v wl-copy &> /dev/null; then > > local copy_cmd=( wl-copy ) > local paste_cmd=( wl-paste -n ) > if [[ $X_SELECTION == primary ]]; then > -- > 2.34.1