summaryrefslogtreecommitdiff
path: root/bin/menuscripts
diff options
context:
space:
mode:
authorRaymaekers Luca <raymaekers.luca@gmail.com>2023-10-15 00:33:26 +0200
committerRaymaekers Luca <raymaekers.luca@gmail.com>2023-10-15 00:33:26 +0200
commit826ce094fecc4c6e07faf6e8b91387c2ae49842c (patch)
tree1820c843e4e260f6b51e8d269a972295a17e558c /bin/menuscripts
parentc032a9d071ee4b7eb2bfe79ec03d2a7dc4020f15 (diff)
parenta915b5ade1a47b9678e2f9963b13b49dbd406031 (diff)
Merge branch 'main' of db:dotfiles
Diffstat (limited to 'bin/menuscripts')
-rwxr-xr-xbin/menuscripts/mpower7
1 files changed, 5 insertions, 2 deletions
diff --git a/bin/menuscripts/mpower b/bin/menuscripts/mpower
index 3b66824..0d0cdcc 100755
--- a/bin/menuscripts/mpower
+++ b/bin/menuscripts/mpower
@@ -1,8 +1,11 @@
#!/bin/sh
-choice="$(printf 'poweroff
+choice="$(
+cat <<EOF | commander -c -w 9 -y 4
+poweroff
suspend
hibernate
reboot
-' | commander -c -d)"
+EOF
+)"
[ "$choice" ] && systemctl "$choice"