23 |
23 |
24 $ hg init $TESTTMP/issue-6028 |
24 $ hg init $TESTTMP/issue-6028 |
25 $ cd $TESTTMP/issue-6028 |
25 $ cd $TESTTMP/issue-6028 |
26 |
26 |
27 create initial commit |
27 create initial commit |
|
28 |
28 $ echo "0" > 0 |
29 $ echo "0" > 0 |
29 $ hg ci -Am 0 |
30 $ hg ci -Am 0 |
30 adding 0 |
31 adding 0 |
31 |
32 |
|
33 start new topics "a" and "b" both from 0 |
32 |
34 |
33 $ hg up default |
35 $ hg up default |
34 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
36 0 files updated, 0 files merged, 0 files removed, 0 files unresolved |
35 $ hg topics a |
37 $ hg topics a |
36 marked working directory as topic: a |
38 marked working directory as topic: a |
38 $ hg ci -Am a |
40 $ hg ci -Am a |
39 adding a |
41 adding a |
40 active topic 'a' grew its first changeset |
42 active topic 'a' grew its first changeset |
41 (see 'hg help topics' for more information) |
43 (see 'hg help topics' for more information) |
42 |
44 |
43 |
|
44 $ hg up default |
45 $ hg up default |
45 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
46 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
46 $ hg topics b |
47 $ hg topics b |
47 marked working directory as topic: b |
48 marked working directory as topic: b |
48 $ echo "b" > b |
49 $ echo "b" > b |
49 $ hg ci -Am b |
50 $ hg ci -Am b |
50 adding b |
51 adding b |
51 active topic 'b' grew its first changeset |
52 active topic 'b' grew its first changeset |
52 (see 'hg help topics' for more information) |
53 (see 'hg help topics' for more information) |
|
54 |
|
55 create branch "integration" from 0, merge topics "a" and "b" into it |
53 |
56 |
54 $ hg up default |
57 $ hg up default |
55 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
58 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
56 $ hg branch integration |
59 $ hg branch integration |
57 marked working directory as branch integration |
60 marked working directory as branch integration |
64 $ hg merge b |
67 $ hg merge b |
65 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
68 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
66 (branch merge, don't forget to commit) |
69 (branch merge, don't forget to commit) |
67 $ hg ci -m "merged b" |
70 $ hg ci -m "merged b" |
68 |
71 |
|
72 commit a bad file on topic "a", merge it into "integration" |
|
73 |
69 $ hg up a |
74 $ hg up a |
70 switching to topic a |
75 switching to topic a |
71 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
76 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
72 $ echo "a bad commit" >> a_bad_commit |
77 $ echo "a bad commit" >> a_bad_commit |
73 $ hg add a_bad_commit |
78 $ hg add a_bad_commit |
76 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
81 1 files updated, 0 files merged, 1 files removed, 0 files unresolved |
77 $ hg merge a |
82 $ hg merge a |
78 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
83 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
79 (branch merge, don't forget to commit) |
84 (branch merge, don't forget to commit) |
80 $ hg ci -m "merged a bad commit" |
85 $ hg ci -m "merged a bad commit" |
|
86 |
|
87 add more commits on both topics and merge them into "integration" |
81 |
88 |
82 $ hg up a |
89 $ hg up a |
83 switching to topic a |
90 switching to topic a |
84 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
91 0 files updated, 0 files merged, 1 files removed, 0 files unresolved |
85 $ echo "aa" >> a |
92 $ echo "aa" >> a |
101 $ hg merge b |
108 $ hg merge b |
102 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
109 1 files updated, 0 files merged, 0 files removed, 0 files unresolved |
103 (branch merge, don't forget to commit) |
110 (branch merge, don't forget to commit) |
104 $ hg ci -m "merged bb" |
111 $ hg ci -m "merged bb" |
105 |
112 |
106 create instability by pruning two changesets, one in a topic, one in a merge |
113 create instability by pruning two changesets, one in a topic, one a merge |
|
114 |
|
115 $ hg log -r 5:6 -T '{rev}: {desc}\n' |
|
116 5: a bad commit |
|
117 6: merged a bad commit |
|
118 |
107 $ hg prune -r 5:6 |
119 $ hg prune -r 5:6 |
108 2 changesets pruned |
120 2 changesets pruned |
109 3 new orphan changesets |
121 3 new orphan changesets |
110 |
122 |
111 $ hg up 4 |
123 $ hg up 4 |
112 2 files updated, 0 files merged, 1 files removed, 0 files unresolved |
124 2 files updated, 0 files merged, 1 files removed, 0 files unresolved |
113 |
125 |
114 start the evolve |
126 start the evolve |
|
127 |
115 $ hg evolve --update --no-all |
128 $ hg evolve --update --no-all |
116 move:[8] merged aa |
129 move:[8] merged aa |
117 atop:[4] merged b |
130 atop:[4] merged b |
118 working directory is now at c920dd828523 |
131 working directory is now at c920dd828523 |
119 |
132 |
|
133 casually checking issue6141: position of p2 is not changed |
|
134 |
|
135 $ hg log -r 'predecessors(.) + .' |
|
136 changeset: 8:3f6f25057afb |
|
137 branch: integration |
|
138 parent: 6:cfc4c333724f |
|
139 parent: 7:61eff7f7bb6c |
|
140 user: test |
|
141 date: Thu Jan 01 00:00:00 1970 +0000 |
|
142 obsolete: rebased using evolve as 11:c920dd828523 |
|
143 summary: merged aa |
|
144 |
|
145 changeset: 11:c920dd828523 |
|
146 branch: integration |
|
147 tag: tip |
|
148 parent: 4:e33aee2c715e |
|
149 parent: 7:61eff7f7bb6c |
|
150 user: test |
|
151 date: Thu Jan 01 00:00:00 1970 +0000 |
|
152 instability: orphan |
|
153 summary: merged aa |
|
154 |
|
155 |
|
156 test that we successfully got rid of the bad file |
|
157 |
|
158 $ hg d --git -r 'predecessors(.)' -r '.' |
|
159 diff --git a/a_bad_commit b/a_bad_commit |
|
160 deleted file mode 100644 |
|
161 --- a/a_bad_commit |
|
162 +++ /dev/null |
|
163 @@ -1,1 +0,0 @@ |
|
164 -a bad commit |
|
165 |
120 evolve creates an obsolete changeset above as 11 |
166 evolve creates an obsolete changeset above as 11 |
|
167 |
121 $ hg evolve -r . |
168 $ hg evolve -r . |
122 cannot solve instability of c920dd828523, skipping |
169 cannot solve instability of c920dd828523, skipping |
123 cannot solve instability of c920dd828523, skipping |
170 cannot solve instability of c920dd828523, skipping |