diff --git a/flake.lock b/flake.lock index d0ffe15..a7229c2 100644 --- a/flake.lock +++ b/flake.lock @@ -20,6 +20,22 @@ "type": "github" } }, + "nixos-hardware": { + "locked": { + "lastModified": 1744633460, + "narHash": "sha256-fbWE4Xpw6eH0Q6in+ymNuDwTkqmFmtxcQEmtRuKDTTk=", + "owner": "NixOS", + "repo": "nixos-hardware", + "rev": "9a049b4a421076d27fee3eec664a18b2066824cb", + "type": "github" + }, + "original": { + "owner": "NixOS", + "ref": "master", + "repo": "nixos-hardware", + "type": "github" + } + }, "nixpkgs": { "locked": { "lastModified": 1744932701, @@ -39,6 +55,7 @@ "root": { "inputs": { "home-manager": "home-manager", + "nixos-hardware": "nixos-hardware", "nixpkgs": "nixpkgs" } } diff --git a/flake.nix b/flake.nix index aafbe6a..afe0008 100644 --- a/flake.nix +++ b/flake.nix @@ -1,6 +1,7 @@ { inputs = { nixpkgs.url = "github:NixOS/nixpkgs/nixos-unstable"; + nixos-hardware.url = "github:NixOS/nixos-hardware/master"; home-manager = { url = "github:nix-community/home-manager"; inputs.nixpkgs.follows = "nixpkgs"; @@ -11,6 +12,7 @@ { self, nixpkgs, + nixos-hardware, home-manager, }@inputs: let diff --git a/host/c2/default.nix b/host/c2/default.nix index 574563a..289e936 100644 --- a/host/c2/default.nix +++ b/host/c2/default.nix @@ -1,14 +1,26 @@ -{ mod, ... }: +{ mod, inputs, ... }: { networking.hostName = "c2"; - imports = with mod; [ - collections.pc-common - ./hardware-configuration.nix - ]; + imports = + with mod; + [ + collections.pc-common + ./hardware-configuration.nix + ] + ++ (with inputs.nixos-hardware.nixosModules; [ + common-cpu-intel + common-pc-laptop + common-pc-laptop-ssd + ]); boot.loader.efi.efiSysMountPoint = "/boot/efi"; + powerManagement = { + enable = true; + cpuFreqGovernor = "ondemand"; + }; + # ====== DON'T CHANGE ====== system.stateVersion = "25.05"; }