comparison mercurial/commands.py @ 31110:7fec37746417

color: add a 'ui.color' option to control color behavior This new option control whether or not color will be used. It mirror the behavior of '--color'. I usually avoid adding new option to '[ui]' as the section is already filled with many option. However, I feel like 'color' is central enough to deserves a spot in this '[ui]' section. For now the option is not documented so it is still marked as experimental. Once it get documented and official, we should be able to deprecate the color extensions. There is more cleanup to do before that documentation is written, but we need this option early to made them. Having that option will allow for more cleanup of the initialisation process and proper separation between color configuration.
author Pierre-Yves David <pierre-yves.david@ens-lyon.org>
date Sat, 25 Feb 2017 19:44:23 +0100
parents 8346b2f09e79
children df0a0734304a
comparison
equal deleted inserted replaced
31109:53230c5bb273 31110:7fec37746417
75 _('change working directory'), _('DIR')), 75 _('change working directory'), _('DIR')),
76 ('y', 'noninteractive', None, 76 ('y', 'noninteractive', None,
77 _('do not prompt, automatically pick the first choice for all prompts')), 77 _('do not prompt, automatically pick the first choice for all prompts')),
78 ('q', 'quiet', None, _('suppress output')), 78 ('q', 'quiet', None, _('suppress output')),
79 ('v', 'verbose', None, _('enable additional output')), 79 ('v', 'verbose', None, _('enable additional output')),
80 ('', 'color', 'never', 80 ('', 'color', '',
81 # i18n: 'always', 'auto', 'never', and 'debug' are keywords 81 # i18n: 'always', 'auto', 'never', and 'debug' are keywords
82 # and should not be translated 82 # and should not be translated
83 _("when to colorize (boolean, always, auto, never, or debug)" 83 _("when to colorize (boolean, always, auto, never, or debug)"
84 " (EXPERIMENTAL)"), 84 " (EXPERIMENTAL)"),
85 _('TYPE')), 85 _('TYPE')),