D4929: cmdutil: sort unresolved paths
indygreg (Gregory Szorc)
phabricator at mercurial-scm.org
Tue Oct 9 19:56:48 UTC 2018
indygreg created this revision.
Herald added a subscriber: mercurial-devel.
Herald added a reviewer: hg-reviewers.
REVISION SUMMARY
I noticed that `hg status` was printing unresolved paths in a
non-deterministic order. This patch fixes that.
I'm not sure if the sorting should be done in
merge.mergestate.unresolved() instead. Either way fixes the
presentation issue.
REPOSITORY
rHG Mercurial
REVISION DETAIL
https://phab.mercurial-scm.org/D4929
AFFECTED FILES
mercurial/cmdutil.py
CHANGE DETAILS
diff --git a/mercurial/cmdutil.py b/mercurial/cmdutil.py
--- a/mercurial/cmdutil.py
+++ b/mercurial/cmdutil.py
@@ -581,7 +581,7 @@
if unresolvedlist:
mergeliststr = '\n'.join(
[' %s' % util.pathto(repo.root, encoding.getcwd(), path)
- for path in unresolvedlist])
+ for path in sorted(unresolvedlist)])
msg = _('''Unresolved merge conflicts:
%s
To: indygreg, #hg-reviewers
Cc: mercurial-devel
More information about the Mercurial-devel
mailing list