From 885ded6ca93837c17631e983eaffcf8f4a9aee8b Mon Sep 17 00:00:00 2001 From: lassulus Date: Tue, 28 Jun 2016 17:39:03 +0200 Subject: l 3 power-action: reverse status check --- lass/3modules/power-action.nix | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'lass/3modules') diff --git a/lass/3modules/power-action.nix b/lass/3modules/power-action.nix index 06a31627..3116514a 100644 --- a/lass/3modules/power-action.nix +++ b/lass/3modules/power-action.nix @@ -84,9 +84,9 @@ let ''; state = pkgs.writeDash "state" '' - if [ "$(cat /sys/class/power_supply/BAT0/status)" = "Charging" ] - then echo "true" - else echo "false" + if [ "$(cat /sys/class/power_supply/BAT0/status)" = "Discharging" ] + then echo "false" + else echo "true" fi ''; -- cgit v1.2.3