Annotation of /alx-src/tags/alxconf-0_6_0-rc13/bin/user_reboot.sh
Parent Directory | Revision Log
Revision 2762 -
(hide annotations)
(download)
(as text)
Thu Aug 11 20:35:12 2011 UTC (13 years, 1 month ago) by niro
File MIME type: application/x-sh
File size: 418 byte(s)
Thu Aug 11 20:35:12 2011 UTC (13 years, 1 month ago) by niro
File MIME type: application/x-sh
File size: 418 byte(s)
tagged 'alxconf-0_6_0-rc13'
1 | niro | 238 | #!/bin/bash |
2 | # reboots the system and displays a nice message | ||
3 | niro | 1998 | # $Id$ |
4 | niro | 238 | # |
5 | |||
6 | niro | 2494 | if [[ -x $(which Xdialog) ]] |
7 | niro | 238 | then |
8 | niro | 1998 | Xdialog \ |
9 | niro | 240 | --title "Reboot" \ |
10 | niro | 238 | --no-buttons \ |
11 | niro | 309 | --infobox "System reboot in progress ..." 6 34 5000 \ |
12 | niro | 238 | & sudo /sbin/reboot |
13 | niro | 2494 | elif [[ -x $(which xmessage) ]] |
14 | niro | 2436 | then |
15 | msg=" | ||
16 | System reboot in progress ... | ||
17 | |||
18 | " | ||
19 | xmessage -center -title "Reboot" -buttons "" "${msg}" \ | ||
20 | & sudo /sbin/reboot | ||
21 | niro | 238 | else |
22 | sudo /sbin/reboot | ||
23 | fi |