Patrick Welche <prlw1@cam.ac.uk>
[netbsd-mini2440.git] / etc / powerd / scripts / reset_button
blobed48a934d9e45e70b6f02a88e890e48f56cda534
1 #!/bin/sh -
3 # $NetBSD: reset_button,v 1.2 2003/10/30 17:32:45 mycroft Exp $
5 # Generic script for reset button events. We simply attempt to
6 # reboot the system gracefully.
8 # Arguments passed by powerd(8):
10 # device event
12 case "${2}" in
13 pressed)
14 /sbin/shutdown -r now "reset button pressed"
15 exit 0
19 logger -p warning "${0}: unsupported event ${2} on device ${1}" >&1
20 exit 1
22 esac