render CLI arguments (sub-commands friendly) defined by argparse module
Project description
sphinx-argparse-cli
Render CLI arguments (sub-commands friendly) defined by the argparse module.
Demo projects:
installation
python -m pip install sphinx-argparse-cli
enable in your conf.py
# just add it to your list of extensions to load within conf.py
extensions = ["sphinx_argparse_cli"]
use
Within the reStructuredText files use the sphinx_argparse_cli directive that takes two arguments:
- the module path to where the parser is defined,
- a no argument function within that module that once called returns the constructed argparse parser
- (optional) a program name that overwrites the autodiscovered running argument parser
.. sphinx_argparse_cli::
:module: a_project.cli
:func: build_parser
:prog: my-cli-program
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
sphinx_argparse_cli-1.1.0.tar.gz
(13.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file sphinx_argparse_cli-1.1.0.tar.gz.
File metadata
- Download URL: sphinx_argparse_cli-1.1.0.tar.gz
- Upload date:
- Size: 13.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f340ecef96681210ceaf6cc1fefab8a806be288b8065c89f790cce248537d088
|
|
| MD5 |
085b7a491ed70ba59d77b1178b91c2da
|
|
| BLAKE2b-256 |
7a2015ad2d04c912b91dea5942c52c1662f110485b3f08adf683143a00adb556
|
File details
Details for the file sphinx_argparse_cli-1.1.0-py3-none-any.whl.
File metadata
- Download URL: sphinx_argparse_cli-1.1.0-py3-none-any.whl
- Upload date:
- Size: 6.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/53.0.0 requests-toolbelt/0.9.1 tqdm/4.56.0 CPython/3.8.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5963811c32b35143b3228c9d65e196cfedfcea0160aaf0d3f5196ae5ce9a934b
|
|
| MD5 |
c13329e0618aa5bf4eba116aa52fe851
|
|
| BLAKE2b-256 |
a00594c182015f6ad81c28f90f0d675115822b9bf31346add3267e4f0bea494e
|