npdoc-cli
A tool built with argparse that utilizes the numpy style guide to generate a command line interface (CLI). Paired with auto-generated documentation with sphinx you can maintain a function's source code, documentation, and CLI all with the same chunk of text.
For example a simple CLI for a function can be made with:
from npdoc_cli import cli
@cli.program
def hello(name: str):
"""
Say hello!
Parameters
----------
name : str
Who is being greeted.
"""
print('hello', name)
cli.build()
cli.print_help()
Which produces a help message like:
usage: hello [-h] name
Say hello!
positional arguments:
name Who is being greeted.
optional arguments:
-h, --help show this help message and exit
Install with pip.
pip install npdoc-cli
For more information, check out the documentation.
Metadata
Release files for npdoc-cli 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| npdoc_cli-0.0.2.tar.gz | 9.8 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| npdoc_cli-0.0.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 17.8 kB
Release files / npdoc_cli-0.0.2.tar.gz
| Download URL | npdoc_cli-0.0.2.tar.gz |
|---|---|
| Size | 9.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5db1f8cc4a6141b956dd3e1513b66da1d46121fbd12f5c878937724dd30c9820
|
|
BLAKE2b-256 checksum How to use checksums |
6e46e0dc091ff6ea7cf78d51da87caeb053d0f87510fc05371e7d9e17f567fc9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Release files / npdoc_cli-0.0.2-py3-none-any.whl
| Download URL | npdoc_cli-0.0.2-py3-none-any.whl |
|---|---|
| Size | 8.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b27e09145962e9803c98e77582129d6e448e10ac880549a23e1328ada03cec36
|
|
BLAKE2b-256 checksum How to use checksums |
dfbe28b747fc34bfc6650ba34cc3bea21fe94790bb5a831d2cd7b9a7b83761ca
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.8
|
Security for npdoc-cli 0.0.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.