Frequently-asked questionsΒΆ
- Is there, or will there be, support for
optparse? - Because
optparsewas deprecated in Python 2.7, we have no plans to support it at present. If you’d still like to usesphinxcontrib.argdoc, see the Python documentation on upgrading optparse code. - My main-like function is not named main. Can I use
sphinxcontrib.argdocwithout changing the function name? - Absolutely. Just set argdoc_main_func to the name of your function
(as a string) in
conf.py. See Processing a main-like function named something other than main for instructions. - My executable scripts use alternate prefix characters.
- Can
sphinxcontrib.argdochandle these? Yes. See Using alternate prefix characters in your ArgumentParser for details. - Does
sphinxcontrib.argdocsupport subcommands? - Yes. You don’t need to do anything special.
sphinxcontrib.argdocwill find these all by itself. - Does
sphinxcontrib.argdocsupport nested subcommands? - Yes. See the Examples.