diff options
author | InigoGutierrez <inigogf.95@gmail.com> | 2022-07-31 11:54:40 +0200 |
---|---|---|
committer | InigoGutierrez <inigogf.95@gmail.com> | 2022-07-31 11:54:40 +0200 |
commit | f832d43206035e4101472a1d07d261952dfdd85d (patch) | |
tree | d2d3d5b0bb58e45c1e21912d08f266f0870a270b /emoji | |
parent | b17f7c8d0e626b976f9888f0d7f1d57c86f05773 (diff) | |
download | scripts-f832d43206035e4101472a1d07d261952dfdd85d.tar.gz scripts-f832d43206035e4101472a1d07d261952dfdd85d.zip |
Swapped echo -e for printf in various scripts.
Diffstat (limited to 'emoji')
-rwxr-xr-x | emoji/emoji.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/emoji/emoji.sh b/emoji/emoji.sh new file mode 100755 index 0000000..dfa22cb --- /dev/null +++ b/emoji/emoji.sh @@ -0,0 +1,9 @@ +#!/bin/sh + +# Feeds an emoji list into dmenu and allows to select one into clipboard + +file="$XDG_CONFIG_HOME/emoji" +selected="$(sed '/^~/d' "$file" | dmenu -i -l 20 -p "Choose an emoji:" | cut -d' ' -f1)" +[ -z "$selected" ] && dunstify -t 2000 "No emoji selected." && exit 0 +echo "$selected" | tr -d '\n' | xsel -ib +dunstify -t 2000 "Copied $(xsel -ob)" |