pycsamt.api.cli.options#
pycsamt.api.cli.options#
Reusable Click option decorators shared across all pyCSAMT commands.
Importing a decorator and stacking it onto a Click command automatically wires up the matching argument name — no need to repeat option strings in every command.
Usage#
import click
from pycsamt.api.cli.options import verbose_option, output_dir_option
@click.command()
@verbose_option
@output_dir_option
def my_command(verbose, output_dir):
...
Functions
Attach verbose, no-color, format, and output-dir to a command. |
- pycsamt.api.cli.options.common_options(f)[source]#
Attach verbose, no-color, format, and output-dir to a command.
- pycsamt.api.cli.options.format_option(f)#
Add the text, JSON, or CSV output-format option to a Click command.
- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.fresh_option(f)#
- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.n_jobs_option(f)#
Add the positive
--jobsparallel-worker option to a Click command.- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.no_cache_option(f)#
Add the
--no-cacheprocessing option to a Click command.- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.no_color_option(f)#
Add the
--no-colorterminal-output option to a Click command.- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.output_dir_option(f)#
Add the writable
--output-dirpath option to a Click command.- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.overwrite_option(f)#
Add the
--overwriteconfirmation-bypass option to a Click command.- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.survey_option(f)#
- Parameters:
f (FC)
- Return type:
FC
- pycsamt.api.cli.options.verbose_option(f)#
Add the repeatable
--verboselogging option to a Click command.- Parameters:
f (FC)
- Return type:
FC