novops: add autocompletion

This commit is contained in:
Matthieu C. 2024-08-27 20:05:08 +02:00 committed by Matthieu Coudron
parent 4dfe798dec
commit dd6c0ee128

View File

@ -4,6 +4,7 @@
, pkg-config
, openssl
, stdenv
, installShellFiles
, libiconv
, darwin
}:
@ -29,6 +30,7 @@ rustPlatform.buildRustPackage rec {
];
nativeBuildInputs = [
installShellFiles
pkg-config # required for openssl-sys
];
@ -38,6 +40,13 @@ rustPlatform.buildRustPackage rec {
"--lib"
];
postInstall = ''
installShellCompletion --cmd novops \
--bash <($out/bin/novops completion bash) \
--fish <($out/bin/novops completion fish) \
--zsh <($out/bin/novops completion zsh)
'';
meta = with lib; {
description = "Cross-platform secret & config manager for development and CI environments";
homepage = "https://github.com/PierreBeucher/novops";