mirror of
https://github.com/edu4rdshl/linuxscripts.git
synced 2026-07-17 23:24:52 +00:00
Shutdown propio
This commit is contained in:
parent
7420fcb66f
commit
133a6cf995
1 changed files with 14 additions and 0 deletions
14
propershutdown
Executable file
14
propershutdown
Executable file
|
|
@ -0,0 +1,14 @@
|
|||
#!/bin/bash
|
||||
|
||||
xmessage "Are you sure you want to shut down the computer?" -center -title "Power options" -font "Monospace bold 10" -default "Cancel" -buttons "Cancel":1,"Log out":2,"Reboot":3,"Shut down":4 >/dev/null
|
||||
|
||||
case $? in
|
||||
1)
|
||||
echo "Exit";;
|
||||
2)
|
||||
openbox --exit;;
|
||||
3)
|
||||
systemctl reboot;;
|
||||
4)
|
||||
systemctl poweroff;;
|
||||
esac
|
||||
Loading…
Add table
Add a link
Reference in a new issue