Show More
@@ -524,7 +524,7 b' def update(repo, node, branchmerge, forc' | |||||
524 | action += manifestmerge(repo, wc, p2, pa, overwrite, partial) |
|
524 | action += manifestmerge(repo, wc, p2, pa, overwrite, partial) | |
525 |
|
525 | |||
526 | ### apply phase |
|
526 | ### apply phase | |
527 | if not branchmerge: # just jump to the new rev |
|
527 | if not branchmerge or fastforward: # just jump to the new rev | |
528 | fp1, fp2, xp1, xp2 = fp2, nullid, xp2, '' |
|
528 | fp1, fp2, xp1, xp2 = fp2, nullid, xp2, '' | |
529 | if not partial: |
|
529 | if not partial: | |
530 | repo.hook('preupdate', throw=True, parent1=xp1, parent2=xp2) |
|
530 | repo.hook('preupdate', throw=True, parent1=xp1, parent2=xp2) | |
@@ -533,7 +533,7 b' def update(repo, node, branchmerge, forc' | |||||
533 |
|
533 | |||
534 | if not partial: |
|
534 | if not partial: | |
535 | repo.dirstate.setparents(fp1, fp2) |
|
535 | repo.dirstate.setparents(fp1, fp2) | |
536 | recordupdates(repo, action, branchmerge) |
|
536 | recordupdates(repo, action, branchmerge and not fastforward) | |
537 | if not branchmerge and not fastforward: |
|
537 | if not branchmerge and not fastforward: | |
538 | repo.dirstate.setbranch(p2.branch()) |
|
538 | repo.dirstate.setbranch(p2.branch()) | |
539 | finally: |
|
539 | finally: |
@@ -19,7 +19,12 b' Fast-forward:' | |||||
19 | $ hg merge b |
|
19 | $ hg merge b | |
20 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
|
20 | 1 files updated, 0 files merged, 0 files removed, 0 files unresolved | |
21 | (branch merge, don't forget to commit) |
|
21 | (branch merge, don't forget to commit) | |
|
22 | $ hg branch | |||
|
23 | default | |||
|
24 | $ hg parent --template '{rev}:{node|short} {branches}: {desc}\n' | |||
|
25 | 1:06c2121185be b: b | |||
22 | $ hg ci -Ammerge |
|
26 | $ hg ci -Ammerge | |
|
27 | created new head | |||
23 |
|
28 | |||
24 | Bogus fast-forward should fail: |
|
29 | Bogus fast-forward should fail: | |
25 |
|
30 |
@@ -208,12 +208,11 b' Fastforward merge:' | |||||
208 | $ hg branch |
|
208 | $ hg branch | |
209 | foo |
|
209 | foo | |
210 | $ hg commit -m'Merge ff into foo' |
|
210 | $ hg commit -m'Merge ff into foo' | |
|
211 | created new head | |||
211 |
$ |
|
212 | $ hg parents | |
212 |
changeset: 6: |
|
213 | changeset: 6:6af8030670c9 | |
213 | branch: foo |
|
214 | branch: foo | |
214 | tag: tip |
|
215 | tag: tip | |
215 | parent: 4:98d14f698afe |
|
|||
216 | parent: 5:6683a60370cb |
|
|||
217 | user: test |
|
216 | user: test | |
218 | date: Thu Jan 01 00:00:00 1970 +0000 |
|
217 | date: Thu Jan 01 00:00:00 1970 +0000 | |
219 | summary: Merge ff into foo |
|
218 | summary: Merge ff into foo |
@@ -413,6 +413,7 b' Check prepush logic with merged branches' | |||||
413 | (branch merge, don't forget to commit) |
|
413 | (branch merge, don't forget to commit) | |
414 |
|
414 | |||
415 | $ hg -R k ci -m merge |
|
415 | $ hg -R k ci -m merge | |
|
416 | created new head | |||
416 |
|
417 | |||
417 | $ hg -R k push -r a j |
|
418 | $ hg -R k push -r a j | |
418 | pushing to j |
|
419 | pushing to j |
General Comments 0
You need to be logged in to leave comments.
Login now