diff --git a/pkgs/tools/misc/aichat/default.nix b/pkgs/tools/misc/aichat/default.nix index 6bd57a6e8e96..5052c38b5f2d 100644 --- a/pkgs/tools/misc/aichat/default.nix +++ b/pkgs/tools/misc/aichat/default.nix @@ -4,6 +4,7 @@ , rustPlatform , fetchFromGitHub , pkg-config +, installShellFiles }: rustPlatform.buildRustPackage rec { @@ -21,6 +22,7 @@ rustPlatform.buildRustPackage rec { nativeBuildInputs = [ pkg-config + installShellFiles ]; buildInputs = lib.optionals stdenv.isDarwin [ @@ -29,6 +31,10 @@ rustPlatform.buildRustPackage rec { darwin.apple_sdk.frameworks.Security ]; + postInstall = '' + installShellCompletion ./scripts/completions/aichat.{bash,fish,zsh} + ''; + meta = with lib; { description = "Use GPT-4(V), Gemini, LocalAI, Ollama and other LLMs in the terminal"; homepage = "https://github.com/sigoden/aichat";