hydra-config/mateamt.nix

39 lines
978 B
Nix
Raw Normal View History

2019-11-15 18:39:55 +01:00
{ pkgs ? import <nixpkgs> {}
}:
with pkgs;
let
2019-12-15 21:27:41 +01:00
mateamtSrc = stdenv.mkDerivation {
name = "mateamt-src";
src = <mateamt>;
phases = [ "unpackPhase" "patchPhase" "installPhase" ];
patchPhase = ''
substituteInPlace default.nix \
--replace \
"builtins.fetchTarball https://github.com/input-output-hk/haskell.nix/archive/master.tar.gz" \
"<haskell-nix>"
'';
installPhase = "cp -ar . $out";
};
mateamt = haskellPackages.callPackage "${mateamtSrc}";
2019-12-15 21:12:48 +01:00
ghcBlacklist = [
2019-12-15 21:27:41 +01:00
# "ghc822"
# "ghc844"
# "ghc881"
# "ghcHEAD"
2019-12-15 21:12:48 +01:00
];
2019-11-15 18:39:55 +01:00
ghcVersions =
builtins.filter (p:
2019-12-15 21:12:48 +01:00
(p == "ghcHEAD" || builtins.match "ghc[[:digit:]]+" p != null) &&
(!builtins.elem p ghcBlacklist)
2019-11-15 18:39:55 +01:00
) (builtins.attrNames haskell.packages);
in
builtins.listToAttrs
(map (ghcVersion: {
name = "mateamt-${ghcVersion}";
value = lib.hydraJob (mateamt {
compiler = ghcVersion;
nixpkgs = pkgs;
});
}) ghcVersions)