aboutsummaryrefslogtreecommitdiff
path: root/systemControl.sh
diff options
context:
space:
mode:
authorInigoGutierrez <inigogf.95@gmail.com>2022-07-31 11:54:40 +0200
committerInigoGutierrez <inigogf.95@gmail.com>2022-07-31 11:54:40 +0200
commitf832d43206035e4101472a1d07d261952dfdd85d (patch)
treed2d3d5b0bb58e45c1e21912d08f266f0870a270b /systemControl.sh
parentb17f7c8d0e626b976f9888f0d7f1d57c86f05773 (diff)
downloadscripts-f832d43206035e4101472a1d07d261952dfdd85d.tar.gz
scripts-f832d43206035e4101472a1d07d261952dfdd85d.zip
Swapped echo -e for printf in various scripts.
Diffstat (limited to 'systemControl.sh')
-rwxr-xr-xsystemControl.sh6
1 files changed, 3 insertions, 3 deletions
diff --git a/systemControl.sh b/systemControl.sh
index a751588..0426363 100755
--- a/systemControl.sh
+++ b/systemControl.sh
@@ -1,9 +1,9 @@
#!/bin/bash
# A dmenu prompt script to control system functions.
-options="lock\nreboot\nshutdown\nsuspend\nhibernate\nexit i3\nexit bspwm"
+options="lock\nreboot\nshutdown\nsuspend\nhibernate\nexit bspwm\nexit i3"
-chosen=$(echo -e "$options" | dmenu -p ">_")
+chosen=$(printf "$options" | dmenu -c -bw 3 -l "$(printf "${options}\n" | wc -l)" -p ">_")
case "$chosen" in
"lock") i3lock.sh ;;
@@ -11,6 +11,6 @@ case "$chosen" in
"shutdown") ~/scripts/prompt.sh Shutdown? "systemctl poweroff" ;;
"suspend") systemctl suspend ;;
"hibernate") ~/scripts/prompt.sh Hibernate? "systemctl hibernate" ;;
- "exit i3") ~/scripts/prompt.sh "Exit i3? (ends X session)" "i3-msg exit" ;;
"exit bspwm") ~/scripts/prompt.sh "Exit bspwm? (ends X session)" "bspc quit" ;;
+ "exit i3") ~/scripts/prompt.sh "Exit i3? (ends X session)" "i3-msg exit" ;;
esac