Merge pull request #168472 from SuperSandro2000/atuin

atuin: simplify completion generation
This commit is contained in:
Sandro 2022-04-13 15:13:36 +02:00 committed by GitHub
commit 482ee5dd2b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -26,15 +26,10 @@ rustPlatform.buildRustPackage rec {
buildInputs = lib.optionals stdenv.isDarwin [ libiconv Security SystemConfiguration ];
postInstall = ''
HOME=$(mktemp -d)
for shell in bash fish zsh; do
$out/bin/atuin gen-completions -s $shell -o .
done
installShellCompletion --cmd atuin \
--bash atuin.bash \
--fish atuin.fish \
--zsh _atuin
--bash <($out/bin/atuin gen-completions -s bash) \
--fish <($out/bin/atuin gen-completions -s fish) \
--zsh <($out/bin/atuin gen-completions -s zsh)
'';
meta = with lib; {