Tweak the menu options

This commit is contained in:
David Heinemeier Hansson
2025-07-06 15:11:56 -07:00
parent 49234a8a16
commit 00b621d7d7

View File

@ -5,18 +5,17 @@
# Function to show power menu
show_power_menu() {
local menu_options="󰐥 Power Off
󰜉 Restart
local menu_options=" Lock
󰤄 Sleep
󰍃 Logout
󰒲 Lock"
󰜉 Restart
󰐥 Shutdown"
# Show menu and get selection
local selection=$(echo -e "$menu_options" | wofi --show dmenu --prompt "Power Options" --width 200 --height 250)
# Show menu and get selection
local selection=$(echo -e "$menu_options" | wofi --show dmenu --prompt "Power Options" --width 200 --height 250)
if [ -n "$selection" ]; then
case "$selection" in
"󰐥 Power Off")
if [ -n "$selection" ]; then
case "$selection" in
"󰐥 Shutdown")
systemctl poweroff
;;
"󰜉 Restart")
@ -25,16 +24,12 @@ if [ -n "$selection" ]; then
"󰤄 Sleep")
systemctl suspend
;;
"󰍃 Logout")
hyprctl dispatch exit
;;
"󰒲 Lock")
" Lock")
hyprlock
;;
*)
;;
esac
fi
*) ;;
esac
fi
}
# Main execution