diff options
Diffstat (limited to 'nixpkgs/pkgs/tools/text/gtree')
-rw-r--r-- | nixpkgs/pkgs/tools/text/gtree/default.nix | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/nixpkgs/pkgs/tools/text/gtree/default.nix b/nixpkgs/pkgs/tools/text/gtree/default.nix new file mode 100644 index 000000000000..d27a2857413c --- /dev/null +++ b/nixpkgs/pkgs/tools/text/gtree/default.nix @@ -0,0 +1,45 @@ +{ lib +, buildGoModule +, fetchFromGitHub +, testers +, gtree +}: + +buildGoModule rec { + pname = "gtree"; + version = "1.10.8"; + + src = fetchFromGitHub { + owner = "ddddddO"; + repo = "gtree"; + rev = "v${version}"; + hash = "sha256-gxX5Cq5SPDNWtwtuo35RW+N/WE0ZximxDlTi9TnTACM="; + }; + + vendorHash = "sha256-5biKUOzYaVY+52f0ewvHslAnb+BM0BuqGrU8wwA3t+E="; + + 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"; + homepage = "https://github.com/ddddddO/gtree"; + changelog = "https://github.com/ddddddO/gtree/releases/tag/${src.rev}"; + license = licenses.bsd2; + maintainers = with maintainers; [ figsoda ]; + }; +} |