Add aliases to click-hotoffthehamster commands
Project description
Add (multiple) aliases to a click group or command.
In your click app:
import click_hotoffthehamster as click
from click_hotoffthehamster 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.
Project details
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
Close
Hashes for click_hotoffthehamster_alias-1.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | af5899f2ddc2b8313f417ad0cbf66a244d0cc806b03d521884a68fa692782e4c |
|
MD5 | 396f3cd520d96d5008af773d5979c29f |
|
BLAKE2b-256 | c31d709536c705668394a7118d8bc7c93a2d1f6636bfc1ce1b201c29fb1fac30 |
Close
Hashes for click_hotoffthehamster_alias-1.0.6-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0fd9e9f8d489c61a8c3e3f6ef43ae0d8a94deb20e1b03f3d69376dba6a3c799d |
|
MD5 | 812765a62d5f2dfe082cc8f1f86bd06b |
|
BLAKE2b-256 | 7abe3b95e8698815f273cf9291c74fac941b106c7b18bc51526588878b151f40 |