Show More
@@ -818,6 +818,23 b' def rebase(ui, repo, **opts):' | |||
|
818 | 818 | opts[r'dest'] = '_destautoorphanrebase(SRC)' |
|
819 | 819 | |
|
820 | 820 | if dryrun: |
|
821 | return _dryrunrebase(ui, repo, **opts) | |
|
822 | elif inmemory: | |
|
823 | try: | |
|
824 | # in-memory merge doesn't support conflicts, so if we hit any, abort | |
|
825 | # and re-run as an on-disk merge. | |
|
826 | overrides = {('rebase', 'singletransaction'): True} | |
|
827 | with ui.configoverride(overrides, 'rebase'): | |
|
828 | return _origrebase(ui, repo, inmemory=inmemory, **opts) | |
|
829 | except error.InMemoryMergeConflictsError: | |
|
830 | ui.warn(_('hit merge conflicts; re-running rebase without in-memory' | |
|
831 | ' merge\n')) | |
|
832 | _origrebase(ui, repo, abort=True) | |
|
833 | return _origrebase(ui, repo, inmemory=False, **opts) | |
|
834 | else: | |
|
835 | return _origrebase(ui, repo, **opts) | |
|
836 | ||
|
837 | def _dryrunrebase(ui, repo, **opts): | |
|
821 | 838 |
|
|
822 | 839 |
|
|
823 | 840 |
|
@@ -834,20 +851,6 b' def rebase(ui, repo, **opts):' | |||
|
834 | 851 |
|
|
835 | 852 |
|
|
836 | 853 |
|
|
837 | elif inmemory: | |
|
838 | try: | |
|
839 | # in-memory merge doesn't support conflicts, so if we hit any, abort | |
|
840 | # and re-run as an on-disk merge. | |
|
841 | overrides = {('rebase', 'singletransaction'): True} | |
|
842 | with ui.configoverride(overrides, 'rebase'): | |
|
843 | return _origrebase(ui, repo, inmemory=inmemory, **opts) | |
|
844 | except error.InMemoryMergeConflictsError: | |
|
845 | ui.warn(_('hit merge conflicts; re-running rebase without in-memory' | |
|
846 | ' merge\n')) | |
|
847 | _origrebase(ui, repo, abort=True) | |
|
848 | return _origrebase(ui, repo, inmemory=False, **opts) | |
|
849 | else: | |
|
850 | return _origrebase(ui, repo, **opts) | |
|
851 | 854 | |
|
852 | 855 | def _origrebase(ui, repo, inmemory=False, leaveunfinished=False, rbsrt=None, |
|
853 | 856 | **opts): |
General Comments 0
You need to be logged in to leave comments.
Login now