summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.config/scripts/power.sh18
1 files changed, 18 insertions, 0 deletions
diff --git a/.config/scripts/power.sh b/.config/scripts/power.sh
index 8b13789..6c5ad4e 100644
--- a/.config/scripts/power.sh
+++ b/.config/scripts/power.sh
@@ -1 +1,19 @@
+#!/bin/bash
+options="lock\nlogout\nshutdown\nreboot"
+choice=$(echo -e "$options" | rofi -dmenu -p "power" -i)
+
+case "$choice" in
+ lock)
+ hyprlock
+ ;;
+ logout)
+ command -v hyprshutdown >/dev/null 2>&1 && hyprshutdown || hyprctl dispatch exit
+ ;;
+ shutdown)
+ shutdown now
+ ;;
+ reboot)
+ reboot
+ ;;
+esac