Merge pull request #91223 from hercules-ci/init-hercules-ci-agent-package

hercules-ci-agent: init at 0.7.2
This commit is contained in:
Robert Hensing 2020-06-21 17:56:19 +02:00 committed by GitHub
commit 838822a2e5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
4 changed files with 27 additions and 0 deletions

@ -2659,6 +2659,9 @@ package-maintainers:
- Agda - Agda
roberth: roberth:
- arion-compose - arion-compose
- hercules-ci-agent
- hercules-ci-api-core
- hercules-ci-api-agent
cdepillabout: cdepillabout:
- pretty-simple - pretty-simple
- spago - spago

@ -96,6 +96,7 @@ self: super: builtins.intersectAttrs super {
# profiling is disabled to allow C++/C mess to work, which is fixed in GHC 8.8 # profiling is disabled to allow C++/C mess to work, which is fixed in GHC 8.8
cachix = disableLibraryProfiling super.cachix; cachix = disableLibraryProfiling super.cachix;
hercules-ci-agent = disableLibraryProfiling super.hercules-ci-agent;
# avoid compiling twice by providing executable as a separate output (with small closure size) # avoid compiling twice by providing executable as a separate output (with small closure size)
niv = enableSeparateBinOutput super.niv; niv = enableSeparateBinOutput super.niv;

@ -0,0 +1,21 @@
{ gnutar, gzip, git, haskell, haskellPackages, lib, makeWrapper }:
let
inherit (haskell.lib) overrideCabal addBuildDepends;
inherit (lib) makeBinPath;
pkg =
# justStaticExecutables is needed due to https://github.com/NixOS/nix/issues/2990
overrideCabal
(addBuildDepends (haskell.lib.justStaticExecutables haskellPackages.hercules-ci-agent) [ makeWrapper ])
(o: {
postInstall = ''
${o.postInstall or ""}
mkdir -p $out/libexec
mv $out/bin/hercules-ci-agent $out/libexec
makeWrapper $out/libexec/hercules-ci-agent $out/bin/hercules-ci-agent --prefix PATH : ${makeBinPath [ gnutar gzip git ]}
'';
});
in pkg // {
meta = pkg.meta // {
position = toString ./default.nix + ":1";
};
}

@ -11414,6 +11414,8 @@ in
# justStaticExecutables is needed due to https://github.com/NixOS/nix/issues/2990 # justStaticExecutables is needed due to https://github.com/NixOS/nix/issues/2990
cachix = haskell.lib.justStaticExecutables haskellPackages.cachix; cachix = haskell.lib.justStaticExecutables haskellPackages.cachix;
hercules-ci-agent = callPackage ../development/tools/continuous-integration/hercules-ci-agent { };
niv = haskellPackages.niv.bin; niv = haskellPackages.niv.bin;
ormolu = haskellPackages.ormolu.bin; ormolu = haskellPackages.ormolu.bin;