diff --git a/flake.nix b/flake.nix index 99a1353..ca24efe 100644 --- a/flake.nix +++ b/flake.nix @@ -59,7 +59,7 @@ } ); in - lib.recursiveUpdate flake rec { + lib.recursiveUpdate (removeAttrs flake ["checks"]) rec { project = cabalProject; # add a required job, that's basically all hydraJobs. hydraJobs = flake.hydraJobs @@ -67,15 +67,26 @@ # This ensure hydra send a status for the required job (even if no change other than commit hash) revision = nixpkgs.writeText "revision" (inputs.self.rev or "dirty"); }; + checks = let + # https://github.com/numtide/flake-utils/issues/121#issuecomment-2589899217 + recurseIntoDeepAttrs = attrs: + lib.recurseIntoAttrs (lib.mapAttrs (_: v: + if builtins.typeOf v == "set" && !lib.isDerivation v + then recurseIntoDeepAttrs v + else v + ) attrs); + in inputs.flake-utils.lib.flattenTree (recurseIntoDeepAttrs flake.hydraJobs); } ); nixConfig = { extra-substituters = [ "https://cache.iog.io" + "https://cache.garnix.io" ]; extra-trusted-public-keys = [ "hydra.iohk.io:f/Ea+s+dFdN+3Y/G+FDgSq+a5NEWhJGzdjvKNGv0/EQ=" + "cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g=" ]; allow-import-from-derivation = true; }; diff --git a/garnix.yaml b/garnix.yaml new file mode 100644 index 0000000..da969a1 --- /dev/null +++ b/garnix.yaml @@ -0,0 +1,3 @@ +builds: + include: + - 'checks.*.*'