Show More
@@ -555,14 +555,19 b' def rebase(ui, repo, **opts):' | |||
|
555 | 555 | collapsedas = newnode |
|
556 | 556 | clearrebased(ui, repo, state, skipped, collapsedas) |
|
557 | 557 | |
|
558 |
|
|
|
558 | tr = None | |
|
559 | try: | |
|
560 | tr = repo.transaction('bookmark') | |
|
559 | 561 | if currentbookmarks: |
|
560 | updatebookmarks(repo, targetnode, nstate, currentbookmarks) | |
|
562 | updatebookmarks(repo, targetnode, nstate, currentbookmarks, tr) | |
|
561 | 563 | if activebookmark not in repo._bookmarks: |
|
562 | 564 | # active bookmark was divergent one and has been deleted |
|
563 | 565 | activebookmark = None |
|
566 | clearstatus(repo) | |
|
567 | tr.close() | |
|
568 | finally: | |
|
569 | release(tr) | |
|
564 | 570 | |
|
565 | clearstatus(repo) | |
|
566 | 571 | ui.note(_("rebase completed\n")) |
|
567 | 572 | util.unlinkpath(repo.sjoin('undo'), ignoremissing=True) |
|
568 | 573 | if skipped: |
@@ -817,7 +822,7 b' def updatemq(repo, state, skipped, **opt' | |||
|
817 | 822 | mq.seriesdirty = True |
|
818 | 823 | mq.savedirty() |
|
819 | 824 | |
|
820 | def updatebookmarks(repo, targetnode, nstate, originalbookmarks): | |
|
825 | def updatebookmarks(repo, targetnode, nstate, originalbookmarks, tr): | |
|
821 | 826 | 'Move bookmarks to their correct changesets, and delete divergent ones' |
|
822 | 827 | marks = repo._bookmarks |
|
823 | 828 | for k, v in originalbookmarks.iteritems(): |
@@ -825,8 +830,7 b' def updatebookmarks(repo, targetnode, ns' | |||
|
825 | 830 | # update the bookmarks for revs that have moved |
|
826 | 831 | marks[k] = nstate[v] |
|
827 | 832 | bookmarks.deletedivergent(repo, [targetnode], k) |
|
828 | ||
|
829 | marks.write() | |
|
833 | marks.recordchange(tr) | |
|
830 | 834 | |
|
831 | 835 | def storestatus(repo, originalwd, target, state, collapse, keep, keepbranches, |
|
832 | 836 | external, activebookmark): |
General Comments 0
You need to be logged in to leave comments.
Login now