ref: cave out instances of userFLake dependencies and intject them as
if functions where contructors
This commit is contained in:
parent
40acfd13e3
commit
6f0392b55e
@ -1,6 +1,8 @@
|
||||
{ lib }:
|
||||
|
||||
{ dir, extern, suites, overrides, multiPkgs, userFlakeNixOS, userFlakeInputs, userFlakeSelf }:
|
||||
{ userFlakeNixOS, userFlakeInputs, userFlakeSelf }:
|
||||
|
||||
{ dir, extern, suites, overrides, multiPkgs }:
|
||||
let
|
||||
defaultSystem = "x86_64-linux";
|
||||
|
||||
@ -91,6 +93,8 @@ let
|
||||
};
|
||||
in
|
||||
lib.os.devosSystem {
|
||||
inherit userFlakeNixOS userFlakeInputs userFlakeSelf;
|
||||
} {
|
||||
inherit specialArgs;
|
||||
system = defaultSystem;
|
||||
modules = modules // { inherit local lib; };
|
||||
|
@ -1,6 +1,8 @@
|
||||
{ lib, utils }:
|
||||
|
||||
{ extern, overrides, userFlakeNixOS, userFlakeSelf, userFlakeInputs }:
|
||||
{ userFlakeNixOS, userFlakeSelf, userFlakeInputs }:
|
||||
|
||||
{ extern, overrides }:
|
||||
(utils.lib.eachDefaultSystem
|
||||
(system:
|
||||
let
|
||||
|
@ -3,23 +3,30 @@ let
|
||||
inherit (dev) os;
|
||||
in
|
||||
|
||||
_: { self, ... } @ args:
|
||||
_: { self, inputs, nixos, ... } @ args:
|
||||
let
|
||||
|
||||
userFlakeSelf = self;
|
||||
userFlakeInputs = inputs;
|
||||
userFlakeNixOS = nixos;
|
||||
|
||||
cfg = (lib.mkFlake.evalOldArgs { inherit args; }).config;
|
||||
|
||||
multiPkgs = os.mkPkgs { inherit (cfg) extern overrides; };
|
||||
multiPkgs = os.mkPkgs
|
||||
{ inherit userFlakeSelf userFlakeInputs userFlakeNixOS; }
|
||||
{ inherit (cfg) extern overrides; };
|
||||
|
||||
outputs = {
|
||||
nixosConfigurations = os.mkHosts {
|
||||
inherit userFlakeSelf multiPkgs;
|
||||
nixosConfigurations = os.mkHosts
|
||||
{ inherit userFlakeSelf userFlakeInputs userFlakeNixOS; }
|
||||
{
|
||||
inherit multiPkgs;
|
||||
inherit (cfg) extern suites overrides;
|
||||
dir = cfg.hosts;
|
||||
};
|
||||
|
||||
homeConfigurations = os.mkHomeConfigurations;
|
||||
homeConfigurations = os.mkHomeConfigurations
|
||||
{ inherit userFlakeSelf; };
|
||||
|
||||
nixosModules = cfg.modules;
|
||||
|
||||
@ -36,7 +43,9 @@ let
|
||||
pkgs = multiPkgs.${system};
|
||||
pkgs-lib = lib.pkgs-lib.${system};
|
||||
# all packages that are defined in ./pkgs
|
||||
legacyPackages = os.mkPackages { inherit pkgs; };
|
||||
legacyPackages = os.mkPackages
|
||||
{ inherit userFlakeSelf; }
|
||||
{ inherit pkgs; };
|
||||
in
|
||||
{
|
||||
checks = pkgs-lib.tests.mkChecks {
|
||||
|
Loading…
Reference in New Issue
Block a user