diff options
author | zowoq <59103226+zowoq@users.noreply.github.com> | 2021-03-18 18:58:03 +1000 |
---|---|---|
committer | zowoq <59103226+zowoq@users.noreply.github.com> | 2021-03-18 18:58:03 +1000 |
commit | cc563d84328bd3e77802a2ea02f2f2e6c1394253 (patch) | |
tree | a443488f8341ed1369a28373944479ab35ab9d99 /pkgs/tools | |
parent | 5a41d0d5a0a7365a1b56a53323fb56fffb89c5fb (diff) |
kapp: install completion
Diffstat (limited to 'pkgs/tools')
-rw-r--r-- | pkgs/tools/networking/kapp/default.nix | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/pkgs/tools/networking/kapp/default.nix b/pkgs/tools/networking/kapp/default.nix index dfb641348714f..2ff2fd8daec11 100644 --- a/pkgs/tools/networking/kapp/default.nix +++ b/pkgs/tools/networking/kapp/default.nix @@ -1,4 +1,4 @@ -{ lib, buildGoModule, fetchFromGitHub }: +{ lib, buildGoModule, fetchFromGitHub, installShellFiles }: buildGoModule rec { pname = "kapp"; version = "0.36.0"; @@ -14,6 +14,15 @@ buildGoModule rec { subPackages = [ "cmd/kapp" ]; + nativeBuildInputs = [ installShellFiles ]; + + postInstall = '' + for shell in bash fish zsh; do + $out/bin/kapp completion $shell > kapp.$shell + installShellCompletion kapp.$shell + done + ''; + meta = with lib; { description = "CLI tool that encourages Kubernetes users to manage bulk resources with an application abstraction for grouping"; homepage = "https://get-kapp.io"; |