fix(backlight): prevent systemd from restoring state

This commit is contained in:
Infinidoge 2022-04-18 09:47:14 -04:00
parent 9c26a4f0bb
commit 60ccc6622c

View file

@ -12,7 +12,8 @@ in
initialCommand = mkOpt str "${getMainProgram pkgs.brightnessctl} set ${cfg.initialValue} --class=backlight";
};
config.systemd.services = mkIf cfg.enable {
config = mkIf cfg.enable {
systemd.services = {
"set-initial-backlight" = {
description = "Sets the initial backlight status on startup";
wantedBy = [ "multi-user.target" ];
@ -20,4 +21,6 @@ in
script = cfg.initialCommand;
};
};
boot.kernelParams = [ "systemd.restore_state=0" ];
};
}