From 0a903ce8a6b31d8d530cc8461a3ce227ec4d5030 Mon Sep 17 00:00:00 2001 From: isabel Date: Thu, 30 Apr 2026 16:41:35 +0100 Subject: [PATCH] nixos/hardware/power: simplify --- modules/nixos/hardware/power/tuned.nix | 21 +++++---------------- 1 file changed, 5 insertions(+), 16 deletions(-) diff --git a/modules/nixos/hardware/power/tuned.nix b/modules/nixos/hardware/power/tuned.nix index f380f14c..4c753751 100644 --- a/modules/nixos/hardware/power/tuned.nix +++ b/modules/nixos/hardware/power/tuned.nix @@ -1,20 +1,9 @@ +{ config, ... }: { - lib, - config, - ... -}: -let - inherit (lib) mkIf; -in -{ - config = mkIf config.garden.profiles.laptop.enable { - services = { - tuned = { - enable = true; + services.tuned = { + inherit (config.garden.profiles.laptop) enable; - # auto magically change the profile based on the battery charging state - ppdSettings.main.battery_detection = true; - }; - }; + # auto magically change the profile based on the battery charging state + ppdSettings.main.battery_detection = true; }; } -- 2.51.2