From fcc60b84e5e3cc44986d40af63f5de488caae909 Mon Sep 17 00:00:00 2001 From: seth Date: Sat, 3 Feb 2024 19:27:26 -0500 Subject: make everything a module --- dev/ci.nix | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'dev/ci.nix') diff --git a/dev/ci.nix b/dev/ci.nix index 2d5f583..e33c088 100644 --- a/dev/ci.nix +++ b/dev/ci.nix @@ -10,11 +10,19 @@ mapCfgsToDerivs = lib.mapAttrs (_: cfg: cfg.activationPackage or cfg.config.system.build.toplevel); getCompatibleCfgs = lib.filterAttrs (_: cfg: lib.elem cfg.pkgs.system ciSystems); - getConfigurations = type: mapCfgsToDerivs (getCompatibleCfgs self."${type}Configurations"); in - { - checks = getOutputs self.checks; - devShells = getOutputs self.devShells; - } - // lib.genAttrs ["nixos" "home"] getConfigurations; + builtins.foldl' lib.recursiveUpdate {} [ + ( + lib.genAttrs + ["nixosConfigurations" "homeConfigurations"] + ( + type: mapCfgsToDerivs (getCompatibleCfgs self."${type}") + ) + ) + ( + lib.genAttrs + ["checks" "devShells"] + (type: getOutputs self.${type}) + ) + ]; } -- cgit v1.2.3