gitea: remove with lib over entire file, remove unused patchShebangs
This commit is contained in:
parent
0261350ec9
commit
1ea0b578d0
1 changed files with 6 additions and 9 deletions
|
@ -12,8 +12,6 @@
|
||||||
, nixosTests
|
, nixosTests
|
||||||
}:
|
}:
|
||||||
|
|
||||||
with lib;
|
|
||||||
|
|
||||||
buildGoPackage rec {
|
buildGoPackage rec {
|
||||||
pname = "gitea";
|
pname = "gitea";
|
||||||
version = "1.16.8";
|
version = "1.16.8";
|
||||||
|
@ -36,19 +34,18 @@ buildGoPackage rec {
|
||||||
];
|
];
|
||||||
|
|
||||||
postPatch = ''
|
postPatch = ''
|
||||||
patchShebangs .
|
|
||||||
substituteInPlace modules/setting/setting.go --subst-var data
|
substituteInPlace modules/setting/setting.go --subst-var data
|
||||||
'';
|
'';
|
||||||
|
|
||||||
nativeBuildInputs = [ makeWrapper ];
|
nativeBuildInputs = [ makeWrapper ];
|
||||||
|
|
||||||
buildInputs = optional pamSupport pam;
|
buildInputs = lib.optional pamSupport pam;
|
||||||
|
|
||||||
preBuild =
|
preBuild =
|
||||||
let
|
let
|
||||||
tags = optional pamSupport "pam"
|
tags = lib.optional pamSupport "pam"
|
||||||
++ optional sqliteSupport "sqlite sqlite_unlock_notify";
|
++ lib.optional sqliteSupport "sqlite sqlite_unlock_notify";
|
||||||
tagsString = concatStringsSep " " tags;
|
tagsString = lib.concatStringsSep " " tags;
|
||||||
in
|
in
|
||||||
''
|
''
|
||||||
export buildFlagsArray=(
|
export buildFlagsArray=(
|
||||||
|
@ -66,14 +63,14 @@ buildGoPackage rec {
|
||||||
cp -R ./go/src/${goPackagePath}/options/locale $out/locale
|
cp -R ./go/src/${goPackagePath}/options/locale $out/locale
|
||||||
|
|
||||||
wrapProgram $out/bin/gitea \
|
wrapProgram $out/bin/gitea \
|
||||||
--prefix PATH : ${makeBinPath [ bash git gzip openssh ]}
|
--prefix PATH : ${lib.makeBinPath [ bash git gzip openssh ]}
|
||||||
'';
|
'';
|
||||||
|
|
||||||
goPackagePath = "code.gitea.io/gitea";
|
goPackagePath = "code.gitea.io/gitea";
|
||||||
|
|
||||||
passthru.tests.gitea = nixosTests.gitea;
|
passthru.tests.gitea = nixosTests.gitea;
|
||||||
|
|
||||||
meta = {
|
meta = with lib; {
|
||||||
description = "Git with a cup of tea";
|
description = "Git with a cup of tea";
|
||||||
homepage = "https://gitea.io";
|
homepage = "https://gitea.io";
|
||||||
license = licenses.mit;
|
license = licenses.mit;
|
||||||
|
|
Loading…
Reference in a new issue