summaryrefslogtreecommitdiff
path: root/etc/functions/check_nobat
diff options
context:
space:
mode:
authorDaniel Friesel <derf@derf.homelinux.org>2009-04-12 23:31:34 +0200
committerDaniel Friesel <derf@derf.homelinux.org>2009-04-12 23:31:34 +0200
commit245049d134096d6040db121c49c8327f9baa9f3d (patch)
tree38ab811c017c9ab3d6a19c600bcd4f58bb59b434 /etc/functions/check_nobat
parentdbd72104cf715daacf74059a3c2f46133ace8b42 (diff)
Renamed check_nobat to check_ac, shortened check
Diffstat (limited to 'etc/functions/check_nobat')
-rw-r--r--etc/functions/check_nobat10
1 files changed, 0 insertions, 10 deletions
diff --git a/etc/functions/check_nobat b/etc/functions/check_nobat
deleted file mode 100644
index 0f5dca3..0000000
--- a/etc/functions/check_nobat
+++ /dev/null
@@ -1,10 +0,0 @@
-## vim:ft=zsh
-## check_nobat - returns true if machine is _not_ running on battery
-typeset state
-typeset -i ret=0
-
-for state in /proc/acpi/battery/*/state(N); {
- fgrep -i 'discharging' $state &> /dev/null && ret=1
-}
-
-return $ret