diff --git a/default.nix b/default.nix index 3b25f31e..8a46f79d 100644 --- a/default.nix +++ b/default.nix @@ -1,6 +1,6 @@ rec { sources = import ./nix/sources.nix; - pkgs = import ./pkgs { }; + pkgs = import ./pkgs { inherit sources; }; witch = import ./lib/witch.nix { lib = pkgs.lib; }; hosts = import ./lib/hosts.nix { inherit pkgs sources witch; }; diff --git a/lib/hosts.nix b/lib/hosts.nix index 44b1083e..9398bebf 100644 --- a/lib/hosts.nix +++ b/lib/hosts.nix @@ -28,7 +28,7 @@ rec { networking = { inherit hostName; }; - nixpkgs.pkgs = import pkgsPath { inherit (config.nixpkgs) config; }; + nixpkgs.pkgs = import pkgsPath { inherit (config.nixpkgs) config; inherit sources; }; }; diff --git a/modules/home/default.nix b/modules/home/default.nix index 582cb772..7dd1ee9f 100644 --- a/modules/home/default.nix +++ b/modules/home/default.nix @@ -1,7 +1,6 @@ -{ ... }: +{ sources, ... }: -let sources = import ../../nix/sources.nix; -in { +{ home-manager.users = { imports = [ (sources.tf-nix + "/modules/home/secrets.nix") diff --git a/modules/nixos/default.nix b/modules/nixos/default.nix index f17cb06f..44b96a6d 100644 --- a/modules/nixos/default.nix +++ b/modules/nixos/default.nix @@ -1,7 +1,6 @@ -{ ... }: +{ sources, ... }: -let sources = import ../../nix/sources.nix; -in { +{ imports = [ ./deploy (sources.tf-nix + "/modules/nixos/secrets.nix") diff --git a/pkgs/default.nix b/pkgs/default.nix index b915f2d6..0c69b311 100644 --- a/pkgs/default.nix +++ b/pkgs/default.nix @@ -1,9 +1,7 @@ -{ config ? { }, system ? builtins.currentSystem, ... }@args: +{ config ? { }, sources, system ? builtins.currentSystem, ... }@args: let - sources = import ../nix/sources.nix; pkgs = import sources.nixpkgs args; - overlay = self: super: rec { dino = super.callPackage "${sources.qyliss-nixlib}/overlays/patches/dino" { inherit (super) dino;