CLI utilities - tmuxp.cli.utils
#
CLI utility helpers for tmuxp.
- tmuxp.cli.utils.tmuxp_echo(message=None, log_level='INFO', style_log=False)[source]#
Combine logging.log and click.echo.
- Return type:
- tmuxp.cli.utils.prompt(name, default=None, value_proc=None)[source]#
Return user input from command line.
- Return type:
- Parameters:
name – prompt text
default – default value if no input provided.
- Return type:
See also
prompt()
,prompt_bool()
andprompt_choices()
are from flask-script. See the flask-script license.
- tmuxp.cli.utils.prompt_bool(name, default=False, yes_choices=None, no_choices=None)[source]#
Return True / False by prompting user input from command line.
- tmuxp.cli.utils.prompt_yes_no(name, default=True)[source]#
prompt_bool()
returning yes by default.- Return type:
- tmuxp.cli.utils.prompt_choices(name, choices, default=None, no_choice=('none',))[source]#
Return user input from command line from set of provided choices.
- exception tmuxp.cli.utils.UnknownStyleColor(color, *args, **kwargs)[source]#
Bases:
Exception
Raised when encountering an unknown terminal style color.