summary refs log tree commit diff
path: root/pkgs/applications/networking/cluster/terraform-docs/default.nix
blob: a5b6e7d2f5e714d0f5001af557c52ca85d0796d1 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
{ lib, buildGoPackage, fetchFromGitHub }:
buildGoPackage rec {
  pname = "terraform-docs";
  version = "0.9.1";

  goPackagePath = "github.com/segmentio/${pname}";

  src = fetchFromGitHub {
    owner  = "segmentio";
    repo   = pname;
    rev    = "v${version}";
    sha256 = "00sfzdqhf8g85m03r6mbzfas5vvc67iq7syb8ljcgxg8l1knxnjx";
  };

  preBuild = ''
    buildFlagsArray+=("-ldflags" "-X main.version=${version}")
  '';

  meta = with lib; {
    description = "A utility to generate documentation from Terraform modules in various output formats";
    homepage = "https://github.com/segmentio/terraform-docs/";
    license = licenses.mit;
    maintainers = with maintainers; [ zimbatm ];
  };
}