diff --git a/shtab/__init__.py b/shtab/__init__.py index 57c6ad1..fd8d7a7 100644 --- a/shtab/__init__.py +++ b/shtab/__init__.py @@ -414,7 +414,7 @@ def format_optional(opt): def format_positional(opt): return '"{nargs}:{help}:{pattern}"'.format( - nargs={"+": "*", "*": "*"}.get(opt.nargs, ""), + nargs={"+": "(*)", "*": "(*):"}.get(opt.nargs, ""), help=escape_zsh((opt.help or opt.dest).strip().split("\n")[0]), pattern=complete2pattern(opt.complete, "zsh", choice_type2fn) if hasattr(opt, "complete")