Show More
@@ -1417,6 +1417,11 b' def verifyactions(actions, state, ctxs):' | |||||
1417 | expected = set(c.node() for c in ctxs) |
|
1417 | expected = set(c.node() for c in ctxs) | |
1418 | seen = set() |
|
1418 | seen = set() | |
1419 | prev = None |
|
1419 | prev = None | |
|
1420 | ||||
|
1421 | if actions and actions[0].verb in ['roll', 'fold']: | |||
|
1422 | raise error.ParseError(_('first changeset cannot use verb "%s"') % | |||
|
1423 | actions[0].verb) | |||
|
1424 | ||||
1420 | for action in actions: |
|
1425 | for action in actions: | |
1421 | action.verify(prev, expected, seen) |
|
1426 | action.verify(prev, expected, seen) | |
1422 | prev = action |
|
1427 | prev = action |
@@ -460,7 +460,7 b' Attempting to fold a change into a publi' | |||||
460 | > EOF |
|
460 | > EOF | |
461 | $ HGEDITOR="sh ../edit.sh" hg histedit 2 |
|
461 | $ HGEDITOR="sh ../edit.sh" hg histedit 2 | |
462 | warning: histedit rules saved to: .hg/histedit-last-edit.txt |
|
462 | warning: histedit rules saved to: .hg/histedit-last-edit.txt | |
463 | hg: parse error: cannot fold into public change 18aa70c8ad22 |
|
463 | hg: parse error: first changeset cannot use verb "fold" | |
464 | [255] |
|
464 | [255] | |
465 | $ cat .hg/histedit-last-edit.txt |
|
465 | $ cat .hg/histedit-last-edit.txt | |
466 | fold 0012be4a27ea 2 extend a |
|
466 | fold 0012be4a27ea 2 extend a |
@@ -541,3 +541,36 b' Editor should have run only once' | |||||
541 | END |
|
541 | END | |
542 |
|
542 | |||
543 | $ cd .. |
|
543 | $ cd .. | |
|
544 | ||||
|
545 | Test rolling into a commit with multiple children (issue5498) | |||
|
546 | ||||
|
547 | $ hg init roll | |||
|
548 | $ cd roll | |||
|
549 | $ echo a > a | |||
|
550 | $ hg commit -qAm aa | |||
|
551 | $ echo b > b | |||
|
552 | $ hg commit -qAm bb | |||
|
553 | $ hg up -q ".^" | |||
|
554 | $ echo c > c | |||
|
555 | $ hg commit -qAm cc | |||
|
556 | $ hg log -G -T '{node|short} {desc}' | |||
|
557 | @ 5db65b93a12b cc | |||
|
558 | | | |||
|
559 | | o 301d76bdc3ae bb | |||
|
560 | |/ | |||
|
561 | o 8f0162e483d0 aa | |||
|
562 | ||||
|
563 | ||||
|
564 | $ hg histedit . --commands - << EOF | |||
|
565 | > r 5db65b93a12b | |||
|
566 | > EOF | |||
|
567 | hg: parse error: first changeset cannot use verb "roll" | |||
|
568 | [255] | |||
|
569 | $ hg log -G -T '{node|short} {desc}' | |||
|
570 | @ 5db65b93a12b cc | |||
|
571 | | | |||
|
572 | | o 301d76bdc3ae bb | |||
|
573 | |/ | |||
|
574 | o 8f0162e483d0 aa | |||
|
575 | ||||
|
576 |
General Comments 0
You need to be logged in to leave comments.
Login now