system/laptop: split logind and auto-cpufreq config
This commit is contained in:
parent
4deded9963
commit
b6b98a126e
4 changed files with 20 additions and 9 deletions
|
|
@ -19,12 +19,12 @@
|
||||||
../../modules/nixos/services/tailscale
|
../../modules/nixos/services/tailscale
|
||||||
../../modules/nixos/services/tailscale/exit-node/client.nix
|
../../modules/nixos/services/tailscale/exit-node/client.nix
|
||||||
|
|
||||||
|
../../modules/nixos/system/laptop
|
||||||
../../modules/nixos/system/colors.nix
|
../../modules/nixos/system/colors.nix
|
||||||
../../modules/nixos/system/console-colors.nix
|
../../modules/nixos/system/console-colors.nix
|
||||||
../../modules/nixos/system/desktop.nix
|
../../modules/nixos/system/desktop.nix
|
||||||
../../modules/nixos/system/fonts.nix
|
../../modules/nixos/system/fonts.nix
|
||||||
../../modules/nixos/system/home-manager.nix
|
../../modules/nixos/system/home-manager.nix
|
||||||
../../modules/nixos/system/laptop.nix
|
|
||||||
../../modules/nixos/system/printing.nix
|
../../modules/nixos/system/printing.nix
|
||||||
../../modules/nixos/system/scx.nix
|
../../modules/nixos/system/scx.nix
|
||||||
../../modules/nixos/system/swap.nix
|
../../modules/nixos/system/swap.nix
|
||||||
|
|
@ -106,4 +106,4 @@
|
||||||
};
|
};
|
||||||
|
|
||||||
system.stateVersion = "24.11";
|
system.stateVersion = "24.11";
|
||||||
}
|
}
|
||||||
|
|
|
||||||
8
modules/nixos/system/laptop.nix → modules/nixos/system/laptop/auto-cpufreq.nix
Normal file → Executable file
8
modules/nixos/system/laptop.nix → modules/nixos/system/laptop/auto-cpufreq.nix
Normal file → Executable file
|
|
@ -1,12 +1,6 @@
|
||||||
{ config, ... }:
|
{ config, ... }:
|
||||||
|
|
||||||
{
|
{
|
||||||
services.logind.settings.Login = {
|
|
||||||
HandleLidSwitch = "suspend";
|
|
||||||
HandleLidSwitchExternalPower = "lock";
|
|
||||||
HandleLidSwitchDocked = "ignore";
|
|
||||||
};
|
|
||||||
|
|
||||||
services = {
|
services = {
|
||||||
tlp.enable = false;
|
tlp.enable = false;
|
||||||
power-profiles-daemon.enable = false;
|
power-profiles-daemon.enable = false;
|
||||||
|
|
@ -33,4 +27,4 @@
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
8
modules/nixos/system/laptop/default.nix
Normal file
8
modules/nixos/system/laptop/default.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
||||||
|
{ config, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./auto-cpufreq.nix
|
||||||
|
./logind.nix
|
||||||
|
];
|
||||||
|
}
|
||||||
9
modules/nixos/system/laptop/logind.nix
Normal file
9
modules/nixos/system/laptop/logind.nix
Normal file
|
|
@ -0,0 +1,9 @@
|
||||||
|
{ config, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
services.logind.settings.Login = {
|
||||||
|
HandleLidSwitch = "suspend";
|
||||||
|
HandleLidSwitchExternalPower = "lock";
|
||||||
|
HandleLidSwitchDocked = "ignore";
|
||||||
|
};
|
||||||
|
}
|
||||||
Loading…
Add table
Add a link
Reference in a new issue