Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/etc/powerd/scripts Add some states not handled before. XXX: ...
details: https://anonhg.NetBSD.org/src/rev/41513368298b
branches: trunk
changeset: 794354:41513368298b
user: christos <christos%NetBSD.org@localhost>
date: Thu Mar 13 00:50:55 2014 +0000
description:
Add some states not handled before. XXX: are both states in the | cases
possible?
diffstat:
etc/powerd/scripts/sensor_battery | 16 +++++++++++++---
1 files changed, 13 insertions(+), 3 deletions(-)
diffs (40 lines):
diff -r 30e27e16cb9e -r 41513368298b etc/powerd/scripts/sensor_battery
--- a/etc/powerd/scripts/sensor_battery Thu Mar 13 00:28:20 2014 +0000
+++ b/etc/powerd/scripts/sensor_battery Thu Mar 13 00:50:55 2014 +0000
@@ -1,6 +1,6 @@
#!/bin/sh -
#
-# $NetBSD: sensor_battery,v 1.7 2010/02/15 22:56:13 pgoyette Exp $
+# $NetBSD: sensor_battery,v 1.8 2014/03/13 00:50:55 christos Exp $
#
# Generic script for battery sensors.
#
@@ -18,16 +18,26 @@
logger -p warning "${0}: (${3}) state changed to ${4} [${1}]" >&1
exit 0
;;
-warning-capacity)
+warning-capacity|warning-under)
logger -p warning \
"${0}: (${3}) capacity below warning limit [${1}]" >&1
exit 0
;;
-critical-capacity)
+critical-capacity|critical-under)
logger -p warning \
"${0}: (${3}) capacity below critical limit [${1}]" >&1
exit 0
;;
+warning-over)
+ logger -p warning \
+ "${0}: (${3}) capacity above warning limit [${1}]" >&1
+ exit 0
+ ;;
+critical-over)
+ logger -p warning \
+ "${0}: (${3}) capacity above critical limit [${1}]" >&1
+ exit 0
+ ;;
high-capacity)
logger -p warning \
"${0}: (${3}) capacity above high limit [${1}]" >&1
Home |
Main Index |
Thread Index |
Old Index