click-aliases
Add (multiple) aliases to a click_ group or command.
In your click app:
import click
from click_aliases import ClickAliasedGroup
@click.group(cls=ClickAliasedGroup)
def cli():
pass
@cli.command(aliases=['bar', 'baz', 'qux'])
def foo():
"""Run a command."""
click.echo('foo')
Will result in:
Usage: cli [OPTIONS] COMMAND [ARGS]...
Options:
--help Show this message and exit.
Commands:
foo (bar,baz,qux) Run a command.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
click_aliases-1.0.7.tar.gz
(3.1 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 click_aliases-1.0.7.tar.gz.
File metadata
- Download URL: click_aliases-1.0.7.tar.gz
- Upload date:
- Size: 3.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
507d6a6cf9001bf8838fe7f58a37651a25cbc5cc25421c5aeab6727a9397f7b5
|
|
| MD5 |
4a5756854df3db7f4b9e675b90999d84
|
|
| BLAKE2b-256 |
0262a67da6b561fad10792635cf504080f3d98b655683c4801570b22f95f3476
|
File details
Details for the file click_aliases-1.0.7-py3-none-any.whl.
File metadata
- Download URL: click_aliases-1.0.7-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.9.25
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f3dc828dbc76de4b6a7262a02049ad00e0107648f3a058df728d966e3fecd464
|
|
| MD5 |
28f04720f3f05f70c29b2b8466f56399
|
|
| BLAKE2b-256 |
872783b5403ab6cfa9ee78e0251308e614df8536679348771575fcdb0e00db4a
|