replace wofi by fuzzel

This commit is contained in:
Frost-Phoenix 2024-06-23 15:24:54 +02:00
parent 535f9fe03d
commit ee3ea9e4ae
7 changed files with 18 additions and 137 deletions

View file

@ -3,4 +3,4 @@
config_file=~/.config/hypr/hyprland.conf
keybinds=$(grep -oP '(?<=bind=).*' $config_file)
keybinds=$(echo "$keybinds" | sed 's/,\([^,]*\)$/ = \1/' | sed 's/, exec//g' | sed 's/^,//g')
wofi -W 750 -dmenu -p "Keybinds" <<< "$keybinds"
fuzzel --width 75 --dmenu <<< "$keybinds"

View file

@ -1,15 +1,15 @@
#!/usr/bin/env zsh
respond="$(echo "------------- Shutdown --------------\n------------- Restart ---------------\n-------------- Cancel ---------------" | wofi --show dmenu -k /dev/null)"
respond="$(echo " Shutdown\n Restart\n Cancel" | fuzzel --dmenu --lines=3 --width=10 --prompt='')"
if [ $respond = '------------- Shutdown --------------' ]
if [ $respond = ' Shutdown' ]
then
echo "shutdown"
shutdown now
elif [ $respond = '------------- Restart ---------------' ]
# shutdown now
elif [ $respond = ' Restart' ]
then
echo "restart"
reboot
# reboot
else
notify-send "cancel shutdown"
fi