forked from GH-forks/shmoji
wayland support (dmenu-wl|wofi) (#4)
This commit is contained in:
parent
6f9016ca68
commit
94914cfaaa
1 changed files with 15 additions and 1 deletions
16
shmoji
16
shmoji
|
@ -6,7 +6,9 @@
|
||||||
# - shmoji download: curl
|
# - shmoji download: curl
|
||||||
# - shmoji fzf: fzf
|
# - shmoji fzf: fzf
|
||||||
# - shmoji bemenu: bemenu & wtype
|
# - shmoji bemenu: bemenu & wtype
|
||||||
|
# - shmoji dmenu: dmenu-wl
|
||||||
# - shmoji rofi: rofi & xdotool
|
# - shmoji rofi: rofi & xdotool
|
||||||
|
# - shmoji rofi: wofi & wl-copy
|
||||||
|
|
||||||
set -e
|
set -e
|
||||||
|
|
||||||
|
@ -47,6 +49,12 @@ case "$cmd" in
|
||||||
emoji=$(cat "$emojifile" | bemenu -c -W 0.2 -l 20)
|
emoji=$(cat "$emojifile" | bemenu -c -W 0.2 -l 20)
|
||||||
emojiprint "$emoji" | wtype -
|
emojiprint "$emoji" | wtype -
|
||||||
;;
|
;;
|
||||||
|
dmenu)
|
||||||
|
emojicheck
|
||||||
|
depends dmenu-wl
|
||||||
|
emoji=$(cat "$emojifile" | dmenu-wl)
|
||||||
|
emojiprint "$emoji"
|
||||||
|
;;
|
||||||
rofi)
|
rofi)
|
||||||
emojicheck
|
emojicheck
|
||||||
depends rofi xdotool
|
depends rofi xdotool
|
||||||
|
@ -54,6 +62,12 @@ case "$cmd" in
|
||||||
emoji=$(cat "$emojifile" | rofi -dmenu | cut -d " " -f 1 | tr -d '\n')
|
emoji=$(cat "$emojifile" | rofi -dmenu | cut -d " " -f 1 | tr -d '\n')
|
||||||
[ "$emoji" ] && xdotool windowactivate --sync $win type --clearmodifiers $emoji
|
[ "$emoji" ] && xdotool windowactivate --sync $win type --clearmodifiers $emoji
|
||||||
;;
|
;;
|
||||||
|
wofi)
|
||||||
|
emojicheck
|
||||||
|
depends wofi wl-copy
|
||||||
|
emoji=$(cat "$emojifile" | wofi -dS dmenu | cut -d " " -f 1 | tr -d '\n')
|
||||||
|
[ "$emoji" ] && wl-copy $emoji
|
||||||
|
;;
|
||||||
fzf)
|
fzf)
|
||||||
emojicheck
|
emojicheck
|
||||||
depends fzf
|
depends fzf
|
||||||
|
@ -61,7 +75,7 @@ case "$cmd" in
|
||||||
emojiprint "$emoji"
|
emojiprint "$emoji"
|
||||||
;;
|
;;
|
||||||
*)
|
*)
|
||||||
printf "%s\n" "usage: shmoji [download | bemenu | rofi | fzf]"
|
printf "%s\n" "usage: shmoji [download | bemenu | dmenu | rofi | wofi | fzf]"
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue