Patchwork [1,of,2] devel-warn: add 'warn-' to 'devel.empty-changegroup' config

login
register
mail settings
Submitter Boris Feld
Date Oct. 16, 2017, 10:17 a.m.
Message ID <b3b1e118238d5897da17.1508149035@FB>
Download mbox | patch
Permalink /patch/24973/
State Accepted
Headers show

Comments

Boris Feld - Oct. 16, 2017, 10:17 a.m.
# HG changeset patch
# User Boris Feld <boris.feld@octobus.net>
# Date 1507491752 -7200
#      Sun Oct 08 21:42:32 2017 +0200
# Node ID b3b1e118238d5897da17c41e66a1ce46ebc8096b
# Parent  a652b7763f669683eb5540c6d4b77ee18e55bc80
# EXP-Topic config.register.fixup
# Available At https://bitbucket.org/octobus/mercurial-devel/
#              hg pull https://bitbucket.org/octobus/mercurial-devel/ -r b3b1e118238d
devel-warn: add 'warn-' to 'devel.empty-changegroup' config

Rename 'devel.empty-changegroup' to 'devel.warn-empty- changegroup' in order
to clarify it controls a warning message.

No alias is installed since the previous configuration option was not
documented.

Patch

diff --git a/mercurial/changegroup.py b/mercurial/changegroup.py
--- a/mercurial/changegroup.py
+++ b/mercurial/changegroup.py
@@ -313,7 +313,7 @@ 
 
             if not cgnodes:
                 repo.ui.develwarn('applied empty changegroup',
-                                  config='empty-changegroup')
+                                  config='warn-empty-changegroup')
             clend = len(cl)
             changesets = clend - clstart
             repo.ui.progress(_('changesets'), None)
diff --git a/mercurial/configitems.py b/mercurial/configitems.py
--- a/mercurial/configitems.py
+++ b/mercurial/configitems.py
@@ -220,7 +220,7 @@ 
 coreconfigitem('devel', 'disableloaddefaultcerts',
     default=False,
 )
-coreconfigitem('devel', 'empty-changegroup',
+coreconfigitem('devel', 'warn-empty-changegroup',
     default=False,
 )
 coreconfigitem('devel', 'legacy.exchange',