From d7a03838527f83587f00841b1fe0aff88438ff67 Mon Sep 17 00:00:00 2001 From: Aly Raffauf Date: Thu, 7 Nov 2024 20:18:06 -0500 Subject: [PATCH] hw/laptop:: only trigger ppd rules with ACAD --- hwModules/common/laptop/default.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hwModules/common/laptop/default.nix b/hwModules/common/laptop/default.nix index 6d290ce9..947ae9ff 100644 --- a/hwModules/common/laptop/default.nix +++ b/hwModules/common/laptop/default.nix @@ -18,8 +18,8 @@ power-profiles-daemon.enable = lib.mkDefault true; udev.extraRules = '' - SUBSYSTEM=="power_supply", ATTR{online}=="1", ACTION=="change", RUN+="${lib.getExe pkgs.power-profiles-daemon} set balanced" - SUBSYSTEM=="power_supply", ATTR{online}=="0", ACTION=="change", RUN+="${lib.getExe pkgs.power-profiles-daemon} set power-saver" + SUBSYSTEM=="power_supply", ENV{POWER_SUPPLY_NAME}=="ACAD", ATTR{online}=="1", ACTION=="change", RUN+="${lib.getExe pkgs.power-profiles-daemon} set balanced" + SUBSYSTEM=="power_supply", ENV{POWER_SUPPLY_NAME}=="ACAD", ATTR{online}=="0", ACTION=="change", RUN+="${lib.getExe pkgs.power-profiles-daemon} set power-saver" ''; upower.enable = lib.mkDefault true;