Show More
@@ -1316,6 +1316,10 b' def pullrebase(orig, ui, repo, *args, **' | |||||
1316 | ui.debug('--update and --rebase are not compatible, ignoring ' |
|
1316 | ui.debug('--update and --rebase are not compatible, ignoring ' | |
1317 | 'the update flag\n') |
|
1317 | 'the update flag\n') | |
1318 |
|
1318 | |||
|
1319 | ui.debug('before rebase: ensure working dir is clean\n') | |||
|
1320 | cmdutil.checkunfinished(repo) | |||
|
1321 | cmdutil.bailifchanged(repo) | |||
|
1322 | ||||
1319 | revsprepull = len(repo) |
|
1323 | revsprepull = len(repo) | |
1320 | origpostincoming = commands.postincoming |
|
1324 | origpostincoming = commands.postincoming | |
1321 | def _dummy(*args, **kwargs): |
|
1325 | def _dummy(*args, **kwargs): |
@@ -1,6 +1,7 b'' | |||||
1 | $ cat >> $HGRCPATH <<EOF |
|
1 | $ cat >> $HGRCPATH <<EOF | |
2 | > [extensions] |
|
2 | > [extensions] | |
3 | > rebase= |
|
3 | > rebase= | |
|
4 | > histedit= | |||
4 | > |
|
5 | > | |
5 | > [alias] |
|
6 | > [alias] | |
6 | > tglog = log -G --template "{rev}: '{desc}' {branches}\n" |
|
7 | > tglog = log -G --template "{rev}: '{desc}' {branches}\n" | |
@@ -72,6 +73,27 b' Re-run:' | |||||
72 | searching for changes |
|
73 | searching for changes | |
73 | no changes found |
|
74 | no changes found | |
74 |
|
75 | |||
|
76 | Abort pull early if working dir is not clean: | |||
|
77 | ||||
|
78 | $ echo L1-mod > L1 | |||
|
79 | $ hg pull --rebase | |||
|
80 | abort: uncommitted changes | |||
|
81 | [255] | |||
|
82 | $ hg update --clean --quiet | |||
|
83 | ||||
|
84 | Abort pull early if another operation (histedit) is in progress: | |||
|
85 | ||||
|
86 | $ hg histedit . -q --commands - << EOF | |||
|
87 | > edit d80cc2da061e histedit: generate unfinished state | |||
|
88 | > EOF | |||
|
89 | Editing (d80cc2da061e), you may commit or record as needed now. | |||
|
90 | (hg histedit --continue to resume) | |||
|
91 | [1] | |||
|
92 | $ hg pull --rebase | |||
|
93 | abort: histedit in progress | |||
|
94 | (use 'hg histedit --continue' or 'hg histedit --abort') | |||
|
95 | [255] | |||
|
96 | $ hg histedit --abort --quiet | |||
75 |
|
97 | |||
76 | Invoke pull --rebase and nothing to rebase: |
|
98 | Invoke pull --rebase and nothing to rebase: | |
77 |
|
99 |
General Comments 0
You need to be logged in to leave comments.
Login now