depot/third_party/nixpkgs/pkgs/development/tools/hclfmt/default.nix
Default email 2c76a4cb41 Project import generated by Copybara.
GitOrigin-RevId: c757e9bd77b16ca2e03c89bf8bc9ecb28e0c06ad
2023-11-16 04:20:00 +00:00

27 lines
766 B
Nix

{ lib, buildGoModule, fetchFromGitHub }:
buildGoModule rec {
pname = "hclfmt";
version = "2.19.1";
src = fetchFromGitHub {
owner = "hashicorp";
repo = "hcl";
rev = "v${version}";
hash = "sha256-A7YfjXdblFGBABD/PeJMzh9WdPeIUWOWAr/UlD3ki28=";
};
vendorHash = "sha256-DA1IKaC+YSBzCfEMqHsHfwu1o5qvYFaFgDoGG0RZnoo=";
# The code repository includes other tools which are not useful. Only build
# hclfmt.
subPackages = [ "cmd/hclfmt" ];
meta = with lib; {
description = "a code formatter for the Hashicorp Configuration Language (HCL) format";
homepage = "https://github.com/hashicorp/hcl/tree/main/cmd/hclfmt";
license = licenses.mpl20;
mainProgram = "hclfmt";
maintainers = with maintainers; [ zimbatm ];
};
}