1 { stdenv, coreutils, fetchFromGitHub, git, lib, makeWrapper, nettools, perl, perlPackages, nixosTests }:
3 stdenv.mkDerivation rec {
7 src = fetchFromGitHub {
11 hash = "sha256-/VBu+aepIrxWc2padPa/WoXbIdKfIwqmA/M8d1GE5FI=";
14 buildInputs = [ nettools perl ];
15 nativeBuildInputs = [ makeWrapper ];
16 propagatedBuildInputs = [ git ];
21 substituteInPlace ./install --replace " 2>/dev/null" ""
22 substituteInPlace src/lib/Gitolite/Hooks/PostUpdate.pm \
23 --replace /usr/bin/perl "${perl}/bin/perl"
24 substituteInPlace src/lib/Gitolite/Hooks/Update.pm \
25 --replace /usr/bin/perl "${perl}/bin/perl"
26 substituteInPlace src/lib/Gitolite/Setup.pm \
27 --replace hostname "${nettools}/bin/hostname"
28 substituteInPlace src/commands/sskm \
29 --replace /bin/rm "${coreutils}/bin/rm"
33 wrapProgram $out/bin/gitolite-shell \
34 --prefix PATH : ${lib.makeBinPath [ git (perl.withPackages (p: [ p.JSON ])) ]}
39 perl ./install -to $out/bin
40 echo ${version} > $out/bin/VERSION
44 gitolite = nixosTests.gitolite;
48 description = "Finely-grained git repository hosting";
49 homepage = "https://gitolite.com/gitolite/index.html";
50 license = licenses.gpl2;
51 platforms = platforms.unix;
52 maintainers = [ maintainers.thoughtpolice maintainers.lassulus maintainers.tomberek ];