depot/third_party/nixpkgs/pkgs/by-name/tr/treefmt2/package.nix
Default email fa5436e0a7 Project import generated by Copybara.
GitOrigin-RevId: e8057b67ebf307f01bdcc8fba94d94f75039d1f6
2024-06-05 17:53:02 +02:00

33 lines
818 B
Nix

{ lib, buildGoModule, fetchFromGitHub }:
buildGoModule rec {
pname = "treefmt";
version = "2.0.0-rc3";
src = fetchFromGitHub {
owner = "numtide";
repo = "treefmt";
rev = "v${version}";
hash = "sha256-vc9MRwwzPSNPdZYwNwP6g4ffKshbRxW7DRrUHbvYLuM=";
};
vendorHash = "sha256-rjdGNfR2DpLZCzL/+3xiZ7gGDd4bPyBT5qMCO+NyWbg=";
subPackages = [ "." ];
CGO_ENABLED = 1;
ldflags = [
"-s"
"-w"
"-X git.numtide.com/numtide/treefmt/build.Name=${pname}"
"-X git.numtide.com/numtide/treefmt/build.Version=v${version}"
];
meta = {
description = "one CLI to format the code tree";
homepage = "https://github.com/numtide/treefmt";
license = lib.licenses.mit;
maintainers = [ lib.maintainers.brianmcgee lib.maintainers.zimbatm ];
mainProgram = "treefmt";
};
}