Open
Description
I am using the :prog:
keyword for the sphinx_argparse_cli
directive but it appears that it only affects the first display of the command name. The main command name for the subcommands is shown as sphinx-build
.
My rst directive
.. sphinx_argparse_cli::
:module: example.cli
:func: parser
:prog: bug-example
:title: Synopsis
My build command: make man
The result with MANWIDTH=80 PAGER=cat man _build/man/prog.1
:
PROG(1) bug-example PROG(1)
NAME
prog - bug example
SYNOPSIS
bug-example [-h] {foo} ...
bug-example options
• -h, --help - show this help message and exit
sphinx-build foo
sphinx-build foo [-h]
sphinx-build foo options
• -h, --help - show this help message and exit
COPYRIGHT
2022, me
Dec 06, 2022 PROG(1)
The full example repository to reproduce this: https://github.com/lucc/sphinx-example