From c7a88a07b9287db9c129914483f6b3ae1ab5404c Mon Sep 17 00:00:00 2001 From: awy Date: Fri, 14 Nov 2025 23:43:38 +0300 Subject: init --- .local/bin/dmenuunicode | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) create mode 100755 .local/bin/dmenuunicode (limited to '.local/bin/dmenuunicode') diff --git a/.local/bin/dmenuunicode b/.local/bin/dmenuunicode new file mode 100755 index 0000000..0289dc6 --- /dev/null +++ b/.local/bin/dmenuunicode @@ -0,0 +1,20 @@ +#!/bin/sh + +# The famous "get a menu of emojis to copy" script. + +# Get user selection via mew from emoji file. +chosen=$(cut -d ';' -f1 ~/.local/share/extras/chars/* | mew -i -l 30 | sed "s/ .*//") + +# Exit if none chosen. +[ -z "$chosen" ] && exit + +# If you run this command with an argument, it will automatically insert the +# character. Otherwise, show a message that the emoji has been copied. +if [ -n "$1" ]; then + # currently only ascii supported in wlrctl + # wlrctl keyboard type"$chosen" + wtype "$chosen" +else + printf "%s" "$chosen" | wl-copy + notify-send "'$chosen' copied to clipboard." & +fi -- cgit v1.2.3