Skip to content

Commit 36d09e3

Browse files
committed
Hide suppressed subcommands
Suppress subcommands set up with `help=argparse.SUPPRESS` this is already the case for options and defaults.
1 parent 2a2a202 commit 36d09e3

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

sphinxarg/ext.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -222,6 +222,9 @@ def print_subcommands(data, nested_content, markdown_help=False, settings=None):
222222
else:
223223
desc = ['Undocumented']
224224

225+
if desc[0] == '==SUPPRESS==':
226+
continue
227+
225228
# Handle nested content
226229
subcontent = []
227230
if child['name'] in definitions:

0 commit comments

Comments
 (0)