Mercurial > hg
changeset 43919:6b6872822b32
config: drop debug messages saying where config was read from
`hg config --debug` includes lines like this:
set config by: $EDITOR
but also lines like this:
$EDITOR: ui.editor=emacs -nw
The `set config by` messages don't seem to provide much additional
information over what we get from the `$EDITOR:`-type message. I could
imagine wanting to see which values got overriden by a later entry,
but that information is already not present. So let's just remove the
first type of output. My next patch would otherwise amplify the
redundant output (there would be one `set config by` for each line in
`mergetools.rc`).
Differential Revision: https://phab.mercurial-scm.org/D7627
author | Martin von Zweigbergk <martinvonz@google.com> |
---|---|
date | Wed, 11 Dec 2019 22:23:42 -0800 |
parents | 86fe85364811 |
children | 4222b9d5d4fb |
files | mercurial/commands.py tests/test-hgrc.t |
diffstat | 2 files changed, 2 insertions(+), 5 deletions(-) [+] |
line wrap: on
line diff
--- a/mercurial/commands.py Wed Dec 11 11:22:37 2019 -0800 +++ b/mercurial/commands.py Wed Dec 11 22:23:42 2019 -0800 @@ -2224,8 +2224,8 @@ if t == b'path': ui.debug(b'read config from: %s\n' % f) elif t == b'items': - for section, name, value, source in f: - ui.debug(b'set config by: %s\n' % source) + # Don't print anything for 'items'. + pass else: raise error.ProgrammingError(b'unknown rctype: %s' % t) untrusted = bool(opts.get(b'untrusted'))
--- a/tests/test-hgrc.t Wed Dec 11 11:22:37 2019 -0800 +++ b/tests/test-hgrc.t Wed Dec 11 22:23:42 2019 -0800 @@ -197,9 +197,6 @@ with environment variables $ PAGER=p1 EDITOR=e1 VISUAL=e2 hg showconfig --debug - set config by: $EDITOR - set config by: $VISUAL - set config by: $PAGER read config from: $TESTTMP/hgrc repo: bundle.mainreporoot=$TESTTMP $PAGER: pager.pager=p1