mateamt: simplify by 1000%
This commit is contained in:
parent
a05c15a3b6
commit
e61e947a2f
43
mateamt.nix
43
mateamt.nix
|
@ -1,38 +1,7 @@
|
||||||
{ pkgs ? import <nixpkgs> {}
|
{ pkgs ? import <nixpkgs> (import <haskell-nix>)
|
||||||
}:
|
}:
|
||||||
with pkgs;
|
{
|
||||||
let
|
mateamt = pkgs.lib.hydraJob (import <mateamt> {
|
||||||
mateamtSrc = stdenv.mkDerivation {
|
inherit pkgs;
|
||||||
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}";
|
|
||||||
ghcBlacklist = [
|
|
||||||
# "ghc822"
|
|
||||||
# "ghc844"
|
|
||||||
# "ghc881"
|
|
||||||
# "ghcHEAD"
|
|
||||||
];
|
|
||||||
ghcVersions =
|
|
||||||
builtins.filter (p:
|
|
||||||
(p == "ghcHEAD" || builtins.match "ghc[[:digit:]]+" p != null) &&
|
|
||||||
(!builtins.elem p ghcBlacklist)
|
|
||||||
) (builtins.attrNames haskell.packages);
|
|
||||||
in
|
|
||||||
|
|
||||||
builtins.listToAttrs
|
|
||||||
(map (ghcVersion: {
|
|
||||||
name = "mateamt-${ghcVersion}";
|
|
||||||
value = lib.hydraJob (mateamt {
|
|
||||||
compiler = ghcVersion;
|
|
||||||
nixpkgs = pkgs;
|
|
||||||
});
|
|
||||||
}) ghcVersions)
|
|
||||||
|
|
Loading…
Reference in New Issue