rhoas: fix shell completion install
This commit is contained in:
parent
b576dab393
commit
2354d26c60
@ -1,4 +1,4 @@
|
||||
{ lib, buildGoModule, fetchFromGitHub, installShellFiles, testers, rhoas }:
|
||||
{ lib, buildGoModule, fetchFromGitHub, stdenv, installShellFiles, testers, rhoas }:
|
||||
|
||||
buildGoModule rec {
|
||||
pname = "rhoas";
|
||||
@ -24,11 +24,11 @@ buildGoModule rec {
|
||||
# Networking tests fail.
|
||||
doCheck = false;
|
||||
|
||||
postInstall = ''
|
||||
postInstall = lib.optionalString (stdenv.buildPlatform.canExecute stdenv.hostPlatform) ''
|
||||
installShellCompletion --cmd rhoas \
|
||||
--bash <($out/bin/rhoas completion bash) \
|
||||
--fish <($out/bin/rhoas completion fish) \
|
||||
--zsh <($out/bin/rhoas completion zsh)
|
||||
--bash <(HOME=$TMP $out/bin/rhoas completion bash) \
|
||||
--fish <(HOME=$TMP $out/bin/rhoas completion fish) \
|
||||
--zsh <(HOME=$TMP $out/bin/rhoas completion zsh)
|
||||
'';
|
||||
|
||||
passthru.tests.version = testers.testVersion {
|
||||
|
Loading…
Reference in New Issue
Block a user