Sphinx extension that automatically documents click applications
Project description
sphinx-click is a Sphinx plugin that allows you to automatically extract documentation from a Click-based application and include it in your docs.
Installation
Install the plugin using pip:
$ pip install sphinx-click
Alternatively, install from source by cloning this repo then running pip locally:
$ pip install .
Usage
Enable the plugin in your Sphinx conf.py file:
extensions = ['sphinx_click']
Once enabled, you can now use the plugin wherever necessary in the documentation.
.. click:: module:parser
:prog: hello-world
:nested: full
Detailed information on the various options available is provided in the documentation.
Alternative
This plugin is perfect to document a Click-based CLI in Sphinx, as it properly renders the help screen and its options in nice HTML with deep links and styling.
However, if you are looking to document the source code of a Click-based CLI, and the result of its execution, you might want to check out click-extra. The latter provides the .. click:example:: and .. click:run:: Sphinx directives so you can capture and render, with full colors, the result of your CLI in your documentation.
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
Built Distribution
File details
Details for the file sphinx_click-5.2.2.tar.gz
.
File metadata
- Download URL: sphinx_click-5.2.2.tar.gz
- Upload date:
- Size: 29.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.9.19
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 191a36dd5b61f2036592a0b36a6ba037ae97b3dd7e8ce9a056588c5605ac7833 |
|
MD5 | 3667bac49811f357bcf03743ae19f888 |
|
BLAKE2b-256 | 17430d3989c243ba02d9562a969468d58fd668f1d2fa6d17d4bdffafb0d04229 |
File details
Details for the file sphinx_click-5.2.2-py3-none-any.whl
.
File metadata
- Download URL: sphinx_click-5.2.2-py3-none-any.whl
- Upload date:
- Size: 9.9 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.0.0 CPython/3.9.19
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 52be92a53e04de98b7228617a35008a4949910a70a597256c62ea4276c6a066d |
|
MD5 | 70b4ecc3c5a437bfc5644de978350aa8 |
|
BLAKE2b-256 | 893a5b54bdd4dab210377272d1689e833a0760a04a28e6cd9c104e67776b9e5d |