mirror of
https://github.com/NixOS/nixpkgs.git
synced 2025-01-26 14:53:52 +00:00
ff1a94e523
The nixpkgs-unstable channel's programs.sqlite was used to identify packages producing exactly one binary, and these automatically added to their package definitions wherever possible.
46 lines
1.2 KiB
Nix
46 lines
1.2 KiB
Nix
{ lib
|
|
, buildGoModule
|
|
, fetchFromGitHub
|
|
, installShellFiles
|
|
}:
|
|
|
|
buildGoModule rec {
|
|
pname = "terraform-backend-git";
|
|
version = "0.1.6";
|
|
|
|
src = fetchFromGitHub {
|
|
owner = "plumber-cd";
|
|
repo = "terraform-backend-git";
|
|
rev = "v${version}";
|
|
hash = "sha256-ZbQfL7uKCFD98HcoeqscZaIsWFvWH0Ytzlqr6fMmXUs=";
|
|
};
|
|
|
|
vendorHash = "sha256-Y/4UgG/2Vp+gxBnGrNpAgRNfPZWJXhVo8TVa/VfOYt0=";
|
|
|
|
nativeBuildInputs = [
|
|
installShellFiles
|
|
];
|
|
|
|
ldflags = [
|
|
"-s"
|
|
"-w"
|
|
"-X=github.com/plumber-cd/terraform-backend-git/cmd.Version=${version}"
|
|
];
|
|
|
|
postInstall = ''
|
|
installShellCompletion --cmd terraform-backend-git \
|
|
--bash <($out/bin/terraform-backend-git completion bash) \
|
|
--fish <($out/bin/terraform-backend-git completion fish) \
|
|
--zsh <($out/bin/terraform-backend-git completion zsh)
|
|
'';
|
|
|
|
meta = with lib; {
|
|
description = "Terraform HTTP Backend implementation that uses Git repository as storage";
|
|
mainProgram = "terraform-backend-git";
|
|
homepage = "https://github.com/plumber-cd/terraform-backend-git";
|
|
changelog = "https://github.com/plumber-cd/terraform-backend-git/blob/${src.rev}/CHANGELOG.md";
|
|
license = licenses.asl20;
|
|
maintainers = with maintainers; [ blaggacao ];
|
|
};
|
|
}
|