diff options
author | Andreas Rammhold <andreas@rammhold.de> | 2024-01-11 22:10:42 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2024-01-11 22:10:42 +0100 |
commit | 3ea9d4e0a4840fd40abbe98dde0205639c3e1918 (patch) | |
tree | 301614ebc4460f29624821fe047ba9fd972e251f /pkgs/applications/version-management | |
parent | d7574dde16a966f759a7507f615210253cc892ac (diff) | |
parent | eb30af1ec3c6f68cd39bda96d223ee5bf78e74e8 (diff) |
Merge pull request #279914 from hax404/ghorg
ghorg: add shell completion
Diffstat (limited to 'pkgs/applications/version-management')
-rw-r--r-- | pkgs/applications/version-management/ghorg/default.nix | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/pkgs/applications/version-management/ghorg/default.nix b/pkgs/applications/version-management/ghorg/default.nix index f76a0f77e54f2..4137b1c374844 100644 --- a/pkgs/applications/version-management/ghorg/default.nix +++ b/pkgs/applications/version-management/ghorg/default.nix @@ -1,4 +1,4 @@ -{ lib, buildGoModule, fetchFromGitHub }: +{ lib, buildGoModule, fetchFromGitHub, installShellFiles }: buildGoModule rec { pname = "ghorg"; @@ -18,6 +18,14 @@ buildGoModule rec { ldflags = [ "-s" "-w" "-X main.version=${version}" ]; + nativeBuildInputs = [ installShellFiles ]; + postInstall = '' + installShellCompletion --cmd ghorg \ + --bash <($out/bin/ghorg completion bash) \ + --fish <($out/bin/ghorg completion fish) \ + --zsh <($out/bin/ghorg completion zsh) + ''; + meta = with lib; { description = "Quickly clone an entire org/users repositories into one directory"; longDescription = '' |