Contents of /alx-src/tags/alxconf-0_6_0-rc7/bin/user_reboot.sh
Parent Directory | Revision Log
Revision 2436 -
(show annotations)
(download)
(as text)
Thu Jun 16 16:21:43 2011 UTC (13 years ago) by niro
Original Path: alx-src/branches/alxconf-060/bin/user_reboot.sh
File MIME type: application/x-sh
File size: 414 byte(s)
Thu Jun 16 16:21:43 2011 UTC (13 years ago) by niro
Original Path: alx-src/branches/alxconf-060/bin/user_reboot.sh
File MIME type: application/x-sh
File size: 414 byte(s)
-support xmessage shutdown|reboot messages if Xdialog was not found
1 | #!/bin/bash |
2 | # reboots the system and displays a nice message |
3 | # $Id$ |
4 | # |
5 | |
6 | if [ -x $(which Xdialog) ] |
7 | then |
8 | Xdialog \ |
9 | --title "Reboot" \ |
10 | --no-buttons \ |
11 | --infobox "System reboot in progress ..." 6 34 5000 \ |
12 | & sudo /sbin/reboot |
13 | elif [ -x $(which xmessage) ] |
14 | then |
15 | msg=" |
16 | System reboot in progress ... |
17 | |
18 | " |
19 | xmessage -center -title "Reboot" -buttons "" "${msg}" \ |
20 | & sudo /sbin/reboot |
21 | else |
22 | sudo /sbin/reboot |
23 | fi |