system/packages/woodpecker/common.nix

37 lines
800 B
Nix

{ lib, fetchFromGitea }:
let
version = "ef1f27d5e3fae7ae6278717f33dde61778a302d1";
srcSha256 = "sha256-4m9+SC4aMU8AVwrgdDoNFf02mh4R6PLmgnGQ2K8dEuk=";
yarnSha256 = "sha256-DZHwITEG+d3Xtj2k4FaWTEFNjJtX7rD0OvG2uuv6xH0=";
in
{
inherit version yarnSha256;
src = fetchFromGitea {
domain = "git.pleshevski.ru";
owner = "infra";
repo = "woodpecker";
rev = version;
sha256 = srcSha256;
};
postBuild = ''
cd $GOPATH/bin
for f in *; do
mv -- "$f" "woodpecker-$f"
done
cd -
'';
ldflags = [
"-s"
"-w"
"-X github.com/woodpecker-ci/woodpecker/version.Version=next"
];
meta = with lib; {
homepage = "https://woodpecker-ci.org/";
license = licenses.asl20;
maintainers = with maintainers; [ ambroisie techknowlogick ];
};
}