aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorGravatar Jonas Gunz <himself@jonasgunz.de> 2020-11-22 00:26:40 +0100
committerGravatar Jonas Gunz <himself@jonasgunz.de> 2020-11-22 00:26:40 +0100
commitdaad6ac8f1238a3111a05d8b2d70f31e1a70da03 (patch)
tree1f139405c6e8673eea727df5d5bc45dc482a1745 /scripts
parent51014d8ea8442e2e5cfb8e27b75bd7b7a3c70d18 (diff)
downloaddotfiles-daad6ac8f1238a3111a05d8b2d70f31e1a70da03.tar.gz
new i3 exit prompt
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/rofi-exit-menu.sh29
1 files changed, 29 insertions, 0 deletions
diff --git a/scripts/rofi-exit-menu.sh b/scripts/rofi-exit-menu.sh
new file mode 100755
index 0000000..57ce492
--- /dev/null
+++ b/scripts/rofi-exit-menu.sh
@@ -0,0 +1,29 @@
+#!/bin/bash
+
+function options() {
+ cat << EOF
+supspend
+shutdown
+reboot
+Xit
+EOF
+}
+
+if [ $# -gt 0 ]; then
+ case "$@" in
+ suspend)
+ systemctl suspend;;
+ shutdown)
+ systemctl shutdown;;
+ reboot)
+ systemctl reboot;;
+ "exit i3")
+ i3-msg exit;;
+ *)
+ options;;
+
+ esac
+else
+ options
+fi
+