2021-01-15 22:18:51 +00:00
|
|
|
{ lib, buildGoPackage, fetchFromGitHub, ronn, installShellFiles }:
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-05-03 17:38:23 +00:00
|
|
|
buildGoPackage rec {
|
2020-04-24 23:36:52 +00:00
|
|
|
pname = "git-lfs";
|
2021-12-06 16:07:01 +00:00
|
|
|
version = "3.0.2";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
rev = "v${version}";
|
|
|
|
owner = "git-lfs";
|
|
|
|
repo = "git-lfs";
|
2021-12-06 16:07:01 +00:00
|
|
|
sha256 = "0k2pzbhd95xixh5aqdwf5pafilg85wl46d04xbb4lx6k3gkfv0f3";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
2020-05-03 17:38:23 +00:00
|
|
|
goPackagePath = "github.com/git-lfs/git-lfs";
|
|
|
|
|
|
|
|
nativeBuildInputs = [ ronn installShellFiles ];
|
|
|
|
|
2021-08-27 14:25:00 +00:00
|
|
|
ldflags = [ "-s" "-w" "-X ${goPackagePath}/config.Vendor=${version}" "-X ${goPackagePath}/config.GitCommit=${src.rev}" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
subPackages = [ "." ];
|
|
|
|
|
2020-05-03 17:38:23 +00:00
|
|
|
postBuild = ''
|
|
|
|
make -C go/src/${goPackagePath} man
|
|
|
|
'';
|
|
|
|
|
|
|
|
postInstall = ''
|
|
|
|
installManPage go/src/${goPackagePath}/man/*.{1,5}
|
|
|
|
'';
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
meta = with lib; {
|
2020-04-24 23:36:52 +00:00
|
|
|
description = "Git extension for versioning large files";
|
|
|
|
homepage = "https://git-lfs.github.com/";
|
2021-10-28 06:52:43 +00:00
|
|
|
changelog = "https://github.com/git-lfs/git-lfs/raw/v${version}/CHANGELOG.md";
|
2020-04-24 23:36:52 +00:00
|
|
|
license = [ licenses.mit ];
|
2020-05-03 17:38:23 +00:00
|
|
|
maintainers = [ maintainers.twey maintainers.marsam ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|