home *** CD-ROM | disk | FTP | other *** search
/ tusportal.tus.k12.pa.us / tusportal.tus.k12.pa.us.tar / tusportal.tus.k12.pa.us / Wyse / latest-image.raw / 0.img / usr / lib / hal / scripts / linux / hal-system-power-reboot-linux < prev    next >
Text File  |  2010-05-09  |  333b  |  19 lines

  1. #!/bin/sh
  2.  
  3. unsupported() {
  4.     echo "org.freedesktop.Hal.Device.SystemPowerManagement.NotSupported" >&2
  5.     echo "No reboot command found" >&2
  6.     exit 1
  7. }
  8.  
  9. #Try for common tools
  10. if [ -x "/sbin/shutdown" ] ; then
  11.     /sbin/shutdown -r now
  12.     exit $?
  13. elif [ -x "/usr/sbin/shutdown" ] ; then
  14.     /usr/sbin/shutdown -r now
  15.     exit $?
  16. else
  17.     unsupported
  18. fi
  19.