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kChi+350ki6MvG3Ax+3yrUZVc1PJtBDreL7dMs7Y3ENafSMhKnBrRaPVMyUHEm2Ygn4cmJ1YiGw4OWha1n7dtRW/uI96lXKDt8iLAQ4WBRojPhYNl4L3b6/6voCgpZUOpd7PgTRc3/00siCmYIOQzAO0HkDsALoNpk8LcCxpPFYTr8dF3bSsAT9fuaLNV6tI2ofbRLXh0gFXYdaWu10eVRrSMUMiH7n3H6EpzLa4sNdyFrK0vU4aSTlBERcjj2rj86dY0XQQL181V7Yhg8m8nyj+BzraRh7et2UXNsVosOnbTa1XX0qFVu+qAVp2BeqC4k31jm0MJk+1pDzkuAPs07z3ITwkDmTHjzxm5qoZyZ1/n37BB6miD+8xJYNH7vBX/yrDW790HbloasQOcXcerNR |
@@ -208,3 +208,4 b' 7f5410dfc8a64bb587d19637deb95d378fd1eb5c' | |||||
208 | 6d121acbb82e65fe4dd3c2318a1b61981b958492 5.3.1 |
|
208 | 6d121acbb82e65fe4dd3c2318a1b61981b958492 5.3.1 | |
209 | 8fca7e8449a847e3cf1054f2c07b51237699fad3 5.3.2 |
|
209 | 8fca7e8449a847e3cf1054f2c07b51237699fad3 5.3.2 | |
210 | 26ce8e7515036d3431a03aaeb7bc72dd96cb1112 5.4rc0 |
|
210 | 26ce8e7515036d3431a03aaeb7bc72dd96cb1112 5.4rc0 | |
|
211 | cf3e07d7648a4371ce584d15dd692e7a6845792f 5.4 |
@@ -1307,6 +1307,26 b' def phabsend(ui, repo, *revs, **opts):' | |||||
1307 | if any(c for c in ctxs if c.obsolete()): |
|
1307 | if any(c for c in ctxs if c.obsolete()): | |
1308 | raise error.Abort(_(b"obsolete commits cannot be posted for review")) |
|
1308 | raise error.Abort(_(b"obsolete commits cannot be posted for review")) | |
1309 |
|
1309 | |||
|
1310 | # Ensure the local commits are an unbroken range. The semantics of the | |||
|
1311 | # --fold option implies this, and the auto restacking of orphans requires | |||
|
1312 | # it. Otherwise A+C in A->B->C will cause B to be orphaned, and C' to | |||
|
1313 | # get A' as a parent. | |||
|
1314 | def _fail_nonlinear_revs(revs, skiprev, revtype): | |||
|
1315 | badnodes = [repo[r].node() for r in revs if r != skiprev] | |||
|
1316 | raise error.Abort( | |||
|
1317 | _(b"cannot phabsend multiple %s revisions: %s") | |||
|
1318 | % (revtype, scmutil.nodesummaries(repo, badnodes)), | |||
|
1319 | hint=_(b"the revisions must form a linear chain"), | |||
|
1320 | ) | |||
|
1321 | ||||
|
1322 | heads = repo.revs(b'heads(%ld)', revs) | |||
|
1323 | if len(heads) > 1: | |||
|
1324 | _fail_nonlinear_revs(heads, heads.max(), b"head") | |||
|
1325 | ||||
|
1326 | roots = repo.revs(b'roots(%ld)', revs) | |||
|
1327 | if len(roots) > 1: | |||
|
1328 | _fail_nonlinear_revs(roots, roots.min(), b"root") | |||
|
1329 | ||||
1310 | fold = opts.get(b'fold') |
|
1330 | fold = opts.get(b'fold') | |
1311 | if fold: |
|
1331 | if fold: | |
1312 | if len(revs) == 1: |
|
1332 | if len(revs) == 1: | |
@@ -1322,13 +1342,6 b' def phabsend(ui, repo, *revs, **opts):' | |||||
1322 | if not opts.get(b"amend"): |
|
1342 | if not opts.get(b"amend"): | |
1323 | raise error.Abort(_(b"cannot fold with --no-amend")) |
|
1343 | raise error.Abort(_(b"cannot fold with --no-amend")) | |
1324 |
|
1344 | |||
1325 | # Ensure the local commits are an unbroken range |
|
|||
1326 | revrange = repo.revs(b'(first(%ld)::last(%ld))', revs, revs) |
|
|||
1327 | if any(r for r in revs if r not in revrange) or any( |
|
|||
1328 | r for r in revrange if r not in revs |
|
|||
1329 | ): |
|
|||
1330 | raise error.Abort(_(b"cannot fold non-linear revisions")) |
|
|||
1331 |
|
||||
1332 | # It might be possible to bucketize the revisions by the DREV value, and |
|
1345 | # It might be possible to bucketize the revisions by the DREV value, and | |
1333 | # iterate over those groups when posting, and then again when amending. |
|
1346 | # iterate over those groups when posting, and then again when amending. | |
1334 | # But for simplicity, require all selected revisions to be for the same |
|
1347 | # But for simplicity, require all selected revisions to be for the same |
@@ -181,7 +181,7 b' Phabsending a skipped commit:' | |||||
181 | 1849d7828727 mapped to old nodes ['1849d7828727'] |
|
181 | 1849d7828727 mapped to old nodes ['1849d7828727'] | |
182 | D7919 - skipped - 1849d7828727: create comment for phabricator test |
|
182 | D7919 - skipped - 1849d7828727: create comment for phabricator test | |
183 |
|
183 | |||
184 |
Phabsend doesn't create an instability when re |
|
184 | Phabsend doesn't create an instability when restacking existing revisions on top | |
185 | of new revisions. |
|
185 | of new revisions. | |
186 |
|
186 | |||
187 | $ hg init reorder |
|
187 | $ hg init reorder | |
@@ -589,6 +589,13 b' Phabimport accepts multiple DREVSPECs' | |||||
589 | applying patch from D7917 |
|
589 | applying patch from D7917 | |
590 | applying patch from D7918 |
|
590 | applying patch from D7918 | |
591 |
|
591 | |||
|
592 | Phabsend requires a linear range of commits | |||
|
593 | ||||
|
594 | $ hg phabsend -r 0+2+3 | |||
|
595 | abort: cannot phabsend multiple head revisions: c44b38f24a45 | |||
|
596 | (the revisions must form a linear chain) | |||
|
597 | [255] | |||
|
598 | ||||
592 | Validate arguments with --fold |
|
599 | Validate arguments with --fold | |
593 |
|
600 | |||
594 | $ hg phabsend --fold -r 1 |
|
601 | $ hg phabsend --fold -r 1 | |
@@ -597,9 +604,6 b' Validate arguments with --fold' | |||||
597 | $ hg phabsend --fold --no-amend -r 1:: |
|
604 | $ hg phabsend --fold --no-amend -r 1:: | |
598 | abort: cannot fold with --no-amend |
|
605 | abort: cannot fold with --no-amend | |
599 | [255] |
|
606 | [255] | |
600 | $ hg phabsend --fold -r 0+3 |
|
|||
601 | abort: cannot fold non-linear revisions |
|
|||
602 | [255] |
|
|||
603 | $ hg phabsend --fold -r 1:: |
|
607 | $ hg phabsend --fold -r 1:: | |
604 | abort: cannot fold revisions with different DREV values |
|
608 | abort: cannot fold revisions with different DREV values | |
605 | [255] |
|
609 | [255] |
General Comments 0
You need to be logged in to leave comments.
Login now