From cc81f219fab1755d3ecde2adbce881f987a9705f Mon Sep 17 00:00:00 2001 From: Randall Winkhart Date: Sat, 26 Nov 2022 23:57:12 -0500 Subject: [PATCH] Use XDG_SESSION_TYPE to check for Wayland, rather than WAYLAND_DISPLAY --- lib/sshyp.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/sshyp.py b/lib/sshyp.py index 4b4bb5d..44958cc 100755 --- a/lib/sshyp.py +++ b/lib/sshyp.py @@ -782,7 +782,7 @@ def copy_data(): # copies a specified field of an entry to the clipboard elif Path("/data/data/com.termux").exists(): # Termux (Android) clipboard detection run(['termux-clipboard-set', _copy_line[_index].rstrip()]) Popen("sleep 30; termux-clipboard-set ''", shell=True) - elif environ.get('WAYLAND_DISPLAY') == 'wayland-0': # Wayland clipboard detection + elif environ.get('XDG_SESSION_TYPE') == 'wayland': # Wayland clipboard detection run(['wl-copy', _copy_line[_index].rstrip()]) Popen('sleep 30; wl-copy -c', shell=True) else: # X11 clipboard detection