From a5c4c7c7f4cf178467e4fde573a48309e2f58afc Mon Sep 17 00:00:00 2001 From: NullBite Date: Sat, 10 Feb 2024 23:12:07 +0100 Subject: [PATCH] apparently i don't know how overlays work --- flake.nix | 14 ++++++++------ 1 file changed, 8 insertions(+), 6 deletions(-) diff --git a/flake.nix b/flake.nix index 2f28359..c66ca06 100644 --- a/flake.nix +++ b/flake.nix @@ -102,10 +102,7 @@ # a Home Manager home.nix for the given user from ./hosts/${hostname}/ mkSystem = let _username=username; _overlays=overlays; in {system, overlays ? _overlays, hostname, username ? _username, stateVersion, extraModules ? [] }: - let - pkgs = import nixpkgs { inherit system overlays; }; - inherit (pkgs) lib; - in lib.nixosSystem { + lib.nixosSystem { inherit system; modules = [ ./system @@ -114,8 +111,13 @@ # Values for every single system that would not conceivably need # to be made modular system.stateVersion = stateVersion; - # not having the freedom to install unfree programs is unfree - nixpkgs.config.allowUnfree = true; + nixpkgs = { + inherit overlays; + config = { + # not having the freedom to install unfree programs is unfree + allowUnfree = true; + }; + }; nix.settings.experimental-features = ["nix-command" "flakes" ]; }) ./hosts/${hostname}/configuration.nix