diff options
author | Judd Vinet <judd@archlinux.org> | 2004-02-19 18:50:09 +0000 |
---|---|---|
committer | Judd Vinet <judd@archlinux.org> | 2004-02-19 18:50:09 +0000 |
commit | d4a5c5ef402ca7315e5429eaccb0748e38b964af (patch) | |
tree | 9b7be5f03c8749b4d1ff6e3d52317c609dd5bb51 /rc.shutdown | |
parent | 45ede7cf9dd872c580e9c2a57a00b0350f035371 (diff) | |
download | initscripts-d4a5c5ef402ca7315e5429eaccb0748e38b964af.tar.xz |
added cleanups by Leif Askeland
Diffstat (limited to 'rc.shutdown')
-rwxr-xr-x | rc.shutdown | 28 |
1 files changed, 7 insertions, 21 deletions
diff --git a/rc.shutdown b/rc.shutdown index 4f6b6d6..9bf8c2d 100755 --- a/rc.shutdown +++ b/rc.shutdown @@ -9,13 +9,9 @@ # avoid staircase effect /bin/stty onlcr -if [ "$USECOLOR" = "YES" -o "$USECOLOR" = "yes" ]; then - echo -e "\033[1;32m| \033[1;37mInitiating Shutdown...\033[1;0m" - echo -e "\033[1;32m|\033[1;0m" -else - echo "| Initiating Shutdown..." - echo "|" -fi +echo " " +printhl "Initiating Shutdown..." +echo " " if [ "$PREVLEVEL" = "3" -o "$PREVLEVEL" = "5" ]; then # Shutdown daemons @@ -74,22 +70,12 @@ stat_done # Power off or reboot if [ "$RUNLEVEL" = "0" ]; then - if [ "$USECOLOR" = "YES" -o "$USECOLOR" = "yes" ]; then - echo -e "\033[1;32m|\033[1;0m" - echo -e "\033[1;31m| \033[1;33mPOWER OFF\033[1;0m" - else - echo "|" - echo "| POWER OFF" - fi + printsep + printhl "${C_H2}POWER OFF" /sbin/poweroff -d -f -i else - if [ "$USECOLOR" = "YES" -o "$USECOLOR" = "yes" ]; then - echo -e "\033[1;32m|\033[1;0m" - echo -e "\033[1;31m| \033[1;33mREBOOTING\033[1;0m" - else - echo "|" - echo "| REBOOTING" - fi + printsep + printhl "${C_H2}REBOOTING.." /sbin/reboot -d -f -i fi |