import cinit from unix.schottelius.org
Signed-off-by: Nico Schottelius <nico@ikn.schottelius.org>
This commit is contained in:
parent
3729fc68eb
commit
423ba10303
13396 changed files with 269468 additions and 0 deletions
27
software/cinit/browse_source/cinit-0.0.4/bin/cinit.shutdown
Normal file
27
software/cinit/browse_source/cinit-0.0.4/bin/cinit.shutdown
Normal file
|
|
@ -0,0 +1,27 @@
|
|||
#!/bin/sh
|
||||
# Nico Schottelius
|
||||
# shutdown system
|
||||
# 2005-05-24
|
||||
|
||||
|
||||
usage()
|
||||
{
|
||||
echo "`basename $0` -[ohr]"
|
||||
echo " Shutdown the system:"
|
||||
echo " -o|--off: Power off"
|
||||
echo " -h|--halt: Halt"
|
||||
echo " -r|--reboot: Reboot"
|
||||
echo " "
|
||||
exit 1
|
||||
}
|
||||
|
||||
if [ $# -ne 1 ]; then
|
||||
usage
|
||||
fi
|
||||
|
||||
case $1 in
|
||||
-r|--reboot) kill -HUP 1 ;;
|
||||
-o|--off) kill -TERM 1 ;;
|
||||
-h|--halt) kill -USR1 1 ;;
|
||||
*) usage ;;
|
||||
esac
|
||||
Loading…
Add table
Add a link
Reference in a new issue