mirror of
https://github.com/SebastianStork/nixos-config.git
synced 2026-01-21 12:51:34 +01:00
Improve clarity of the optimization option
This commit is contained in:
parent
ad3f4782dd
commit
a3f4c3d6a6
3 changed files with 7 additions and 4 deletions
|
|
@ -24,7 +24,7 @@
|
|||
vpn.lgs.enable = true;
|
||||
comma.enable = true;
|
||||
sops.enable = true;
|
||||
auto-cpufreq.enable = true;
|
||||
optimization.mode = "powersave";
|
||||
doas.enable = false;
|
||||
nix-helper.enable = true;
|
||||
};
|
||||
|
|
|
|||
|
|
@ -9,7 +9,7 @@
|
|||
./auto-gc.nix
|
||||
./sops.nix
|
||||
./bluetooth.nix
|
||||
./auto-cpufreq.nix
|
||||
./optimization.nix
|
||||
./x-input.nix
|
||||
./de.nix
|
||||
./dm.nix
|
||||
|
|
|
|||
|
|
@ -3,9 +3,12 @@
|
|||
lib,
|
||||
...
|
||||
}: {
|
||||
options.myConfig.auto-cpufreq.enable = lib.mkEnableOption "";
|
||||
options.myConfig.optimization.mode = lib.mkOption {
|
||||
type = lib.types.str;
|
||||
default = "";
|
||||
};
|
||||
|
||||
config = lib.mkIf config.myConfig.auto-cpufreq.enable {
|
||||
config = lib.mkIf (config.myConfig.optimization.mode == "powersave") {
|
||||
services.auto-cpufreq = {
|
||||
enable = true;
|
||||
settings = {
|
||||
Loading…
Add table
Add a link
Reference in a new issue