Skip to content

Commit

Permalink
WIP aws-sso-cli add shell completions to package
Browse files Browse the repository at this point in the history
  • Loading branch information
ghthor authored Feb 17, 2024
1 parent a4d4fe8 commit c7c2ea6
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion pkgs/tools/admin/aws-sso-cli/default.nix
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,12 @@ buildGoModule rec {
"-X main.Tag=nixpkgs"
];

postInstall = ''
postInstall = lib.optionalString (stdenv.buildPlatform == stdenv.targetPlatform) ''
installShellCompletion --cmd aws-sso \
--bash <($out/bin/aws-sso completions --source --shell=bash) \
--fish <($out/bin/aws-sso completions --source --shell=fish) \
--zsh <($out/bin/aws-sso completions --source --shell=zsh)
'' + ''
wrapProgram $out/bin/aws-sso \
--suffix PATH : ${lib.makeBinPath [ xdg-utils ]}
'';
Expand Down

0 comments on commit c7c2ea6

Please sign in to comment.