2023-07-15 17:15:38 +00:00
|
|
|
{ lib, buildGoModule, fetchFromGitHub, installShellFiles }:
|
|
|
|
|
2020-12-07 07:45:13 +00:00
|
|
|
buildGoModule rec {
|
|
|
|
pname = "ytt";
|
2024-01-25 14:12:00 +00:00
|
|
|
version = "0.47.0";
|
2020-12-07 07:45:13 +00:00
|
|
|
|
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "vmware-tanzu";
|
|
|
|
repo = "carvel-ytt";
|
|
|
|
rev = "v${version}";
|
2024-01-25 14:12:00 +00:00
|
|
|
sha256 = "sha256-aoKgXagCygK4pzRHw5Nf8LCzpzZd2X77th9tJA5f1aA=";
|
2020-12-07 07:45:13 +00:00
|
|
|
};
|
|
|
|
|
2023-05-24 13:37:59 +00:00
|
|
|
vendorHash = null;
|
2020-12-07 07:45:13 +00:00
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
nativeBuildInputs = [ installShellFiles ];
|
|
|
|
|
2022-08-12 12:06:08 +00:00
|
|
|
ldflags = [
|
|
|
|
"-X github.com/vmware-tanzu/carvel-ytt/pkg/version.Version=${version}"
|
|
|
|
];
|
|
|
|
|
2020-12-07 07:45:13 +00:00
|
|
|
subPackages = [ "cmd/ytt" ];
|
|
|
|
|
2023-07-15 17:15:38 +00:00
|
|
|
postInstall = ''
|
|
|
|
installShellCompletion --cmd ytt \
|
|
|
|
--bash <($out/bin/ytt completion bash) \
|
|
|
|
--fish <($out/bin/ytt completion fish) \
|
|
|
|
--zsh <($out/bin/ytt completion zsh)
|
|
|
|
'';
|
|
|
|
|
2020-12-07 07:45:13 +00:00
|
|
|
meta = with lib; {
|
|
|
|
description = "YAML templating tool that allows configuration of complex software via reusable templates with user-provided values";
|
|
|
|
homepage = "https://get-ytt.io";
|
|
|
|
license = licenses.asl20;
|
2022-06-16 17:23:12 +00:00
|
|
|
maintainers = with maintainers; [ brodes techknowlogick ];
|
2020-12-07 07:45:13 +00:00
|
|
|
};
|
|
|
|
}
|