From fe61d95b44382d4b06e4a4cc42af55e1e62c0dbe Mon Sep 17 00:00:00 2001 From: Sanjay Santhanam <51058514+Sanjays2402@users.noreply.github.com> Date: Sat, 9 May 2026 10:47:34 -0700 Subject: [PATCH] fix(completion): use valid zsh _arguments exclusion-group syntax The generated zsh completion script used `(-h --help)` as the exclusion group for `_arguments`, which zsh rejects with: _arguments:comparguments: invalid argument: (-h --help){-h,--help}[...] Exclusion groups in `_arguments` cannot contain long options. Use the canonical `(-)` form (exclude all other options) which correctly handles flag pairs like `-h`/`--help`. Fixes NousResearch/hermes-agent#22686 --- hermes_cli/completion.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/hermes_cli/completion.py b/hermes_cli/completion.py index 18de08cc901..591ffecc62f 100644 --- a/hermes_cli/completion.py +++ b/hermes_cli/completion.py @@ -216,9 +216,9 @@ _hermes() {{ typeset -A opt_args _arguments -C \\ - '(-h --help){{-h,--help}}[Show help and exit]' \\ - '(-V --version){{-V,--version}}[Show version and exit]' \\ - '(-p --profile){{-p,--profile}}[Profile name]:profile:_hermes_profiles' \\ + '(-)'{{-h,--help}}'[Show help and exit]' \\ + '(-)'{{-V,--version}}'[Show version and exit]' \\ + '(-)'{{-p,--profile}}'[Profile name]:profile:_hermes_profiles' \\ '1:command:->commands' \\ '*::arg:->args'