# HG changeset patch # User Boris Feld <boris.f...@octobus.net> # Date 1498786993 -7200 # Fri Jun 30 03:43:13 2017 +0200 # Node ID 29c443ad962b078b1814489d41d94dd77d161568 # Parent 6a03f7849f92bc11612fda4a599c5c3fc317ceaf # EXP-Topic config.register.core configitems: register the 'merge.preferancestor' config
diff -r 6a03f7849f92 -r 29c443ad962b mercurial/configitems.py --- a/mercurial/configitems.py Fri Jun 30 03:39:10 2017 +0200 +++ b/mercurial/configitems.py Fri Jun 30 03:43:13 2017 +0200 @@ -302,6 +302,9 @@ coreconfigitem('merge', 'followcopies', default=True, ) +coreconfigitem('merge', 'preferancestor', + default=lambda: ['*'], +) coreconfigitem('pager', 'ignore', default=list, ) diff -r 6a03f7849f92 -r 29c443ad962b mercurial/context.py --- a/mercurial/context.py Fri Jun 30 03:39:10 2017 +0200 +++ b/mercurial/context.py Fri Jun 30 03:43:13 2017 +0200 @@ -656,7 +656,7 @@ anc = cahs[0] else: # experimental config: merge.preferancestor - for r in self._repo.ui.configlist('merge', 'preferancestor', ['*']): + for r in self._repo.ui.configlist('merge', 'preferancestor'): try: ctx = changectx(self._repo, r) except error.RepoLookupError: diff -r 6a03f7849f92 -r 29c443ad962b mercurial/merge.py --- a/mercurial/merge.py Fri Jun 30 03:39:10 2017 +0200 +++ b/mercurial/merge.py Fri Jun 30 03:43:13 2017 +0200 @@ -1566,7 +1566,7 @@ p2 = repo[node] if pas[0] is None: - if repo.ui.configlist('merge', 'preferancestor', ['*']) == ['*']: + if repo.ui.configlist('merge', 'preferancestor') == ['*']: cahs = repo.changelog.commonancestorsheads(p1.node(), p2.node()) pas = [repo[anc] for anc in (sorted(cahs) or [nullid])] else: _______________________________________________ Mercurial-devel mailing list Mercurial-devel@mercurial-scm.org https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel