Show More
@@ -646,23 +646,28 b' def _histedit(ui, repo, *freeargs, **opt' | |||
|
646 | 646 | if os.path.exists(repo.sjoin('undo')): |
|
647 | 647 | os.unlink(repo.sjoin('undo')) |
|
648 | 648 | |
|
649 | ||
|
650 | def bootstrapcontinue(ui, repo, parentctx, rules, opts): | |
|
651 | action, currentnode = rules.pop(0) | |
|
652 | ctx = repo[currentnode] | |
|
649 | def gatherchildren(repo, ctx): | |
|
653 | 650 | # is there any new commit between the expected parent and "." |
|
654 | 651 | # |
|
655 | 652 | # note: does not take non linear new change in account (but previous |
|
656 | 653 | # implementation didn't used them anyway (issue3655) |
|
657 |
newchildren = [c.node() for c in repo.set('(%d::.)', |
|
|
658 |
if |
|
|
654 | newchildren = [c.node() for c in repo.set('(%d::.)', ctx)] | |
|
655 | if ctx.node() != node.nullid: | |
|
659 | 656 | if not newchildren: |
|
660 |
# ` |
|
|
661 |
# currentnode is not a descendant from |
|
|
657 | # `ctx` should match but no result. This means that | |
|
658 | # currentnode is not a descendant from ctx. | |
|
662 | 659 | msg = _('%s is not an ancestor of working directory') |
|
663 | 660 | hint = _('use "histedit --abort" to clear broken state') |
|
664 |
raise util.Abort(msg % |
|
|
665 |
newchildren.pop(0) # remove |
|
|
661 | raise util.Abort(msg % ctx, hint=hint) | |
|
662 | newchildren.pop(0) # remove ctx | |
|
663 | return newchildren | |
|
664 | ||
|
665 | def bootstrapcontinue(ui, repo, parentctx, rules, opts): | |
|
666 | action, currentnode = rules.pop(0) | |
|
667 | ctx = repo[currentnode] | |
|
668 | ||
|
669 | newchildren = gatherchildren(repo, parentctx) | |
|
670 | ||
|
666 | 671 | # Commit dirty working directory if necessary |
|
667 | 672 | new = None |
|
668 | 673 | m, a, r, d = repo.status()[:4] |
General Comments 0
You need to be logged in to leave comments.
Login now