Skip to content

Commit 4a005ff

Browse files
committed
Add requiredJobs for testing evalPlatform
1 parent 8d2bbcc commit 4a005ff

File tree

1 file changed

+23
-0
lines changed

1 file changed

+23
-0
lines changed

flake.nix

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -163,6 +163,29 @@
163163
ci = import ./ci.nix { inherit (self.internal) compat; inherit system; };
164164
in stripAttrsForHydra (filterDerivations ci);
165165

166+
requiredJobs =
167+
let
168+
inherit (legacyPackages) lib;
169+
names = x: lib.filter (n: n != "recurseForDerivations" && n != "meta")
170+
(builtins.attrNames x);
171+
in
172+
builtins.listToAttrs (
173+
lib.concatMap (nixpkgsVer:
174+
let nixpkgsJobs = allJobs.${nixpkgsVer};
175+
in lib.concatMap (compiler-nix-name:
176+
let ghcJobs = nixpkgsJobs.${compiler-nix-name};
177+
in (
178+
builtins.map (crossPlatform: {
179+
name = "required-${nixpkgsVer}-${compiler-nix-name}-${crossPlatform}";
180+
value = legacyPackages.releaseTools.aggregate {
181+
name = "haskell.nix-${nixpkgsVer}-${compiler-nix-name}-${crossPlatform}";
182+
meta.description = "All ${nixpkgsVer} ${compiler-nix-name} ${crossPlatform} jobs";
183+
constituents = lib.collect (d: lib.isDerivation d) ghcJobs.${crossPlatform};
184+
};
185+
}) (names ghcJobs))
186+
) (names nixpkgsJobs)
187+
) (names allJobs));
188+
166189
ciJobs = allJobs;
167190

168191
hydraJobs = ciJobs;

0 commit comments

Comments
 (0)