[PATCH RFC] ui: add support for a tweakdefaults knob

Augie Fackler raf at durin42.com
Thu Jun 15 10:09:08 EDT 2017


> On Jun 15, 2017, at 01:14, Martin von Zweigbergk <martinvonz at google.com> wrote:
> 
> At what config level is the tweaking done?

It's done really late, because it's plausible that the user-level or repo-level hgrc would contain ui.tweakdefaults=True. It checks for all the config entries it wants to set, and if anything is already set to a value it doesn't make any changes.

> I didn't understand the
> code well enough to tell.


> Concretely, let's say I have
> ui.tweakdefaults=yes in my system setting and
> command.status.relative=no in my local settings would I get relative
> status or not? I would assume not.

You would not get relative status.

> How about the inverse
> (command.status.relative=no in my system settings and
> ui.tweakdefaults=yes in my local settings)?

You would also not get relative status.

> I'm not sure what I would
> expect in this case, but probably to not get relative status. (It's a
> weird example because there's no reason to set
> command.status.relative=no in the system settings, but there are
> probably more reasonable examples for non-boolean options).

Yeah, it's definitely rough around the edges, but I think it's better than not having the feature.


More information about the Mercurial-devel mailing list