From c9d939e8e9d7845233820952276178c24a5914cf Mon Sep 17 00:00:00 2001 From: zachir Date: Tue, 8 Jul 2025 11:51:08 -0500 Subject: dmenuunicode to wl or x clip --- dmenuunicode | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/dmenuunicode b/dmenuunicode index ef7a63d..1769cb6 100755 --- a/dmenuunicode +++ b/dmenuunicode @@ -14,9 +14,11 @@ esac done if [ -n "$WAYLAND_DISPLAY" ]; then DMENU="tofi" DEFARGS="-c $HOME/.config/tofi/themes/dmenu_vertical" + CLIP="wl-copy" elif [ -n "$DISPLAY" ]; then DMENU="dmenu " DEFARGS="-l 10" + CLIP="xclip -selection clipboard" else print "Can't tell if Wayland or X; what gives?\n" exit 1 @@ -33,6 +35,6 @@ chosen=$(cut -d ';' -f1 ~/.local/share/larbs/chars/* | $DMENU $DEFARGS $ARGS | s if [ -n "$1" ]; then xdotool type "$chosen" else - printf "$chosen" | xclip -selection clipboard + printf "$chosen" | $CLIP notify-send "'$chosen' copied to clipboard." & fi -- cgit v1.2.3