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 / sbin / boot-mode < prev    next >
Text File  |  2012-08-08  |  820b  |  37 lines

  1. #!/bin/bash
  2.  
  3. CONFIG=/etc/sysconfig/thinclient
  4. TMP_CONFIG=${CONFIG}.tmp
  5.  
  6. function usage ()
  7. {
  8.     echo "Usage: $0 <option>"
  9.     echo "Options:"
  10.     echo "  --update     Boot process will check and apply image updates"
  11.     echo "  --no-update  Boot process will not check or apply image updates"
  12.     echo "  --status     Prints the current boot mode"
  13.     exit 1
  14. }
  15.  
  16. echo "WARNING: This tool is deprecated in favor of 'thinclient-config'" >/dev/stderr
  17.  
  18. case $1 in
  19.     --update)
  20.     /usr/sbin/thinclient-config --set-update-mode both
  21.         ;;
  22.     --no-update)
  23.     /usr/sbin/thinclient-config --set-update-mode none
  24.         ;;
  25.     --status)
  26.     updateMode=`/usr/sbin/thinclient-config --get-update-mode`
  27.     if [ "$updateMode" = "none" ]; then
  28.         echo "no-update"
  29.     else
  30.         echo "update"
  31.     fi
  32.         ;;
  33.     *)
  34.         usage
  35.         ;;
  36. esac
  37.