diff options
author | InigoGutierrez <inigogf.95@gmail.com> | 2019-04-09 16:17:17 +0200 |
---|---|---|
committer | InigoGutierrez <inigogf.95@gmail.com> | 2019-04-09 16:17:17 +0200 |
commit | 1682691d00ce85a63fca32455153f4bfd855553f (patch) | |
tree | c1785d04155ec5190298ace71a273af4dafd5554 /emoji.sh | |
parent | 9cdffc48ff753d9bb0087a8728bbd5a68c09f87b (diff) | |
download | scripts-1682691d00ce85a63fca32455153f4bfd855553f.tar.gz scripts-1682691d00ce85a63fca32455153f4bfd855553f.zip |
Created emoji.sh to search and copy an emoji.
Diffstat (limited to 'emoji.sh')
-rwxr-xr-x | emoji.sh | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/emoji.sh b/emoji.sh new file mode 100755 index 0000000..6cc6ca5 --- /dev/null +++ b/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="$(cat "$file" | dmenu -i -l 20 -p "Choose an emoji:" | cut -d' ' -f1)" +[ -z "$selected" ] && dunstify "No emoji selected." && exit 0 +echo "$selected" | xsel -ib +dunstify "Copied $(xsel -ob)" |