reset_button revision 1.2
11.1Sthorpej#!/bin/sh -
21.1Sthorpej#
31.2Smycroft#	$NetBSD: reset_button,v 1.2 2003/10/30 17:32:45 mycroft Exp $
41.1Sthorpej#
51.1Sthorpej# Generic script for reset button events.  We simply attempt to
61.1Sthorpej# reboot the system gracefully.
71.1Sthorpej#
81.1Sthorpej# Arguments passed by powerd(8):
91.1Sthorpej#
101.1Sthorpej#	device event
111.1Sthorpej
121.1Sthorpejcase "${2}" in
131.1Sthorpejpressed)
141.1Sthorpej	/sbin/shutdown -r now
151.1Sthorpej	exit 0
161.1Sthorpej	;;
171.1Sthorpej
181.1Sthorpej*)
191.2Smycroft	logger -p warning "${0}: unsupported event ${2} on device ${1}" >&1
201.1Sthorpej	exit 1
211.1Sthorpej	;;
221.1Sthorpejesac
23