summaryrefslogtreecommitdiff
path: root/.config/scripts/power.sh
blob: 18fea9d25a86e50dd921724dab8a32aef8bdc1a0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
options="lock\nlogout\nshutdown\nreboot"
choice=$(echo -e "$options" | rofi -dmenu -i -p ">")

case "$choice" in
    lock)
        hyprlock
        ;;
    logout)
        command -v hyprshutdown >/dev/null 2>&1 && hyprshutdown || hyprctl dispatch exit
        ;;
    shutdown)
        shutdown now
        ;;
    reboot)
        reboot
        ;;
esac