mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-29 18:33:00 +00:00
47 lines
957 B
Nix
47 lines
957 B
Nix
{ lib
|
|
, buildGoModule
|
|
, fetchFromGitHub
|
|
, testers
|
|
, gtree
|
|
}:
|
|
|
|
buildGoModule rec {
|
|
pname = "gtree";
|
|
version = "1.10.10";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "ddddddO";
|
|
repo = "gtree";
|
|
rev = "v${version}";
|
|
hash = "sha256-sljqO1aYVD7l3ngAeShqzAXKSannBHY7Cx19Kf1xPa0=";
|
|
};
|
|
|
|
vendorHash = "sha256-yxbnASN3vUpRdsxfVsN/zigfpPJKcJaLfFBTtUUW2t0=";
|
|
|
|
subPackages = [
|
|
"cmd/gtree"
|
|
];
|
|
|
|
ldflags = [
|
|
"-s"
|
|
"-w"
|
|
"-X=main.Version=${version}"
|
|
"-X=main.Revision=${src.rev}"
|
|
];
|
|
|
|
passthru.tests = {
|
|
version = testers.testVersion {
|
|
package = gtree;
|
|
};
|
|
};
|
|
|
|
meta = with lib; {
|
|
description = "Generate directory trees and directories using Markdown or programmatically";
|
|
mainProgram = "gtree";
|
|
homepage = "https://github.com/ddddddO/gtree";
|
|
changelog = "https://github.com/ddddddO/gtree/releases/tag/${src.rev}";
|
|
license = licenses.bsd2;
|
|
maintainers = with maintainers; [ figsoda ];
|
|
};
|
|
}
|