def debug_param(msg, value, padding=30): """ helper method to debug parameter values, with alignment :param str msg: the message :param Object value: the value :param int padding: padding for the message """ fmt = '{0: <' + str(padding) + '} : {1}' debug(fmt.format(msg, click.style(str(value), fg=get_color('debug'))))
def echo_target(msg, verbose=True): """ convenience method to display a message using the **blue** ANSI color, the method relies on :func:`click.secho` :param str msg: the message :param bool verbose: echo message only if True """ if verbose: click.secho(msg, fg=get_color('target'))
def echo_success(msg, verbose=True, nl=True): """ convenience method to display a message using the **green** ANSI color, the method relies on :func:`click.secho` :param str msg: the message :param bool verbose: echo message only if True :param bool nl: print new line """ if verbose: click.secho(msg, fg=get_color('success'), nl=nl)