X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=contrib%2Fhooks%2Fpre-auto-gc-battery;h=1f914c94aa748f57bd6c70fdd18dfb681c684556;hb=4deca329f5da1552c8d087975dd5107519cabef7;hp=b0a8caae9e7822fd4ea5c6e9b202373b2947e6af;hpb=769b008e0eaef6876e68c65538f81f841b53cb8e;p=git.git diff --git a/contrib/hooks/pre-auto-gc-battery b/contrib/hooks/pre-auto-gc-battery index b0a8caae9..1f914c94a 100644 --- a/contrib/hooks/pre-auto-gc-battery +++ b/contrib/hooks/pre-auto-gc-battery @@ -28,6 +28,9 @@ elif grep -q 'on-line' /proc/acpi/ac_adapter/AC/state 2>/dev/null then exit 0 elif grep -q '0x01$' /proc/apm 2>/dev/null +then + exit 0 +elif grep -q "AC Power \+: 1" /proc/pmu/info 2>/dev/null then exit 0 elif test -x /usr/bin/pmset && /usr/bin/pmset -g batt |