changeset 44076:a7c4bcf7018a

phabricator: post revisions in ascending topological order (issue6241) The parent in phabricator ends up being the last revision posted, so sorting the user input into ascending order should be enough to preserve the proper relationships. Differential Revision: https://phab.mercurial-scm.org/D7874
author Matt Harbison <matt_harbison@yahoo.com>
date Tue, 14 Jan 2020 16:37:45 -0500
parents 2122ffa903ea
children 05881d002cb2
files hgext/phabricator.py
diffstat 1 files changed, 1 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/phabricator.py	Tue Jan 14 16:29:03 2020 -0500
+++ b/hgext/phabricator.py	Tue Jan 14 16:37:45 2020 -0500
@@ -1065,6 +1065,7 @@
     opts = pycompat.byteskwargs(opts)
     revs = list(revs) + opts.get(b'rev', [])
     revs = scmutil.revrange(repo, revs)
+    revs.sort()  # ascending order to preserve topological parent/child in phab
 
     if not revs:
         raise error.Abort(_(b'phabsend requires at least one changeset'))