Created
June 20, 2019 04:01
-
-
Save davidrios/41d72ef3f97104400c353bab3b1b89ab to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
RESP=$(cat <<EOF | fzf | |
Logout | |
Sleep | |
Reboot | |
Shutdown | |
EOF | |
); | |
case "$RESP" in | |
Logout) | |
swaymsg exit | |
;; | |
Sleep) | |
systemctl suspend | |
;; | |
Reboot) | |
systemctl reboot | |
;; | |
Shutdown) | |
systemctl poweroff | |
;; | |
*) | |
exit 1 | |
esac |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment