--no-color option introduced
This commit is contained in:
parent
8f92912852
commit
1a34b9b61c
@ -192,10 +192,11 @@ AVAILABLE_CLI_OPTIONS = {
|
|||||||
default=False,
|
default=False,
|
||||||
),
|
),
|
||||||
"print_colorized": Arg(
|
"print_colorized": Arg(
|
||||||
'--color', '--print-colorized',
|
'--no-color',
|
||||||
help='Print colorized hyperopt results.',
|
help='Disable colorization of hyperopt results. May be useful if you are '
|
||||||
action='store_true',
|
'redirecting output to a file.',
|
||||||
default=False
|
action='store_false',
|
||||||
|
default=True,
|
||||||
),
|
),
|
||||||
"hyperopt_jobs": Arg(
|
"hyperopt_jobs": Arg(
|
||||||
'-j', '--job-workers',
|
'-j', '--job-workers',
|
||||||
|
@ -254,8 +254,9 @@ class Configuration(object):
|
|||||||
self._args_to_config(config, argname='print_all',
|
self._args_to_config(config, argname='print_all',
|
||||||
logstring='Parameter --print-all detected ...')
|
logstring='Parameter --print-all detected ...')
|
||||||
|
|
||||||
self._args_to_config(config, argname='print_colorized',
|
if 'print_colorized' in self.args and not self.args.print_colorized:
|
||||||
logstring='Parameter --color/--print-colorized detected ...')
|
logger.info('Parameter --no-color detected ...')
|
||||||
|
config.update({'print_colorized': getattr(self.args, 'print_colorized')})
|
||||||
|
|
||||||
self._args_to_config(config, argname='hyperopt_jobs',
|
self._args_to_config(config, argname='hyperopt_jobs',
|
||||||
logstring='Parameter -j/--job-workers detected: {}')
|
logstring='Parameter -j/--job-workers detected: {}')
|
||||||
|
Loading…
Reference in New Issue
Block a user