grafana-alloy: install shell completions
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
, nodejs
|
||||
, grafana-alloy
|
||||
, nix-update-script
|
||||
, installShellFiles
|
||||
, testers
|
||||
}:
|
||||
|
||||
@@ -26,7 +27,7 @@ buildGoModule rec {
|
||||
proxyVendor = true;
|
||||
vendorHash = "sha256-6Xc2siImM1Dl716uGhtAGcn+PO2OLuYLxanzg8Ho6SA=";
|
||||
|
||||
nativeBuildInputs = [ fixup-yarn-lock yarn nodejs ];
|
||||
nativeBuildInputs = [ fixup-yarn-lock yarn nodejs installShellFiles ];
|
||||
|
||||
ldflags =
|
||||
let
|
||||
@@ -93,6 +94,13 @@ buildGoModule rec {
|
||||
$out/bin/alloy
|
||||
'';
|
||||
|
||||
postInstall = ''
|
||||
installShellCompletion --cmd alloy \
|
||||
--bash <($out/bin/alloy completion bash) \
|
||||
--fish <($out/bin/alloy completion fish) \
|
||||
--zsh <($out/bin/alloy completion zsh)
|
||||
'';
|
||||
|
||||
passthru = {
|
||||
tests = {
|
||||
version = testers.testVersion {
|
||||
|
||||
Reference in New Issue
Block a user