Show More
@@ -184,3 +184,72 b' Check for issue3074' | |||
|
184 | 184 | $ hg status |
|
185 | 185 | M newfile |
|
186 | 186 | $ cd .. |
|
187 | ||
|
188 | Create x and y, then modify y and rename x to z on one side of merge, and | |
|
189 | modify x and rename y to z on the other side. | |
|
190 | $ hg init conflicting-target | |
|
191 | $ cd conflicting-target | |
|
192 | $ echo x > x | |
|
193 | $ echo y > y | |
|
194 | $ hg ci -Aqm 'add x and y' | |
|
195 | $ hg mv x z | |
|
196 | $ echo foo >> y | |
|
197 | $ hg ci -qm 'modify y, rename x to z' | |
|
198 | $ hg co -q 0 | |
|
199 | $ hg mv y z | |
|
200 | $ echo foo >> x | |
|
201 | $ hg ci -qm 'modify x, rename y to z' | |
|
202 | # We should probably tell the user about the conflicting rename sources. | |
|
203 | # Depending on which side they pick, we should take that rename and get | |
|
204 | # the changes to the source from the other side. The unchanged file should | |
|
205 | # remain. | |
|
206 | # we should not get the prompts about modify/delete conflicts | |
|
207 | $ hg merge --debug 1 -t :merge3 | |
|
208 | all copies found (* = to merge, ! = divergent, % = renamed and deleted): | |
|
209 | src: 'x' -> dst: 'z' | |
|
210 | checking for directory renames | |
|
211 | resolving manifests | |
|
212 | branchmerge: True, force: False, partial: False | |
|
213 | ancestor: 5151c134577e, local: 07fcbc9a74ed+, remote: f21419739508 | |
|
214 | preserving x for resolve of x | |
|
215 | preserving z for resolve of z | |
|
216 | x: prompt changed/deleted -> m (premerge) | |
|
217 | picked tool ':prompt' for x (binary False symlink False changedelete True) | |
|
218 | file 'x' was deleted in other [merge rev] but was modified in local [working copy]. | |
|
219 | You can use (c)hanged version, (d)elete, or leave (u)nresolved. | |
|
220 | What do you want to do? u | |
|
221 | y: prompt deleted/changed -> m (premerge) | |
|
222 | picked tool ':prompt' for y (binary False symlink False changedelete True) | |
|
223 | file 'y' was deleted in local [working copy] but was modified in other [merge rev]. | |
|
224 | You can use (c)hanged version, leave (d)eleted, or leave (u)nresolved. | |
|
225 | What do you want to do? u | |
|
226 | z: both created -> m (premerge) | |
|
227 | picked tool ':merge3' for z (binary False symlink False changedelete False) | |
|
228 | merging z | |
|
229 | my z@07fcbc9a74ed+ other z@f21419739508 ancestor z@000000000000 | |
|
230 | z: both created -> m (merge) | |
|
231 | picked tool ':merge3' for z (binary False symlink False changedelete False) | |
|
232 | my z@07fcbc9a74ed+ other z@f21419739508 ancestor z@000000000000 | |
|
233 | warning: conflicts while merging z! (edit, then use 'hg resolve --mark') | |
|
234 | 0 files updated, 0 files merged, 0 files removed, 3 files unresolved | |
|
235 | use 'hg resolve' to retry unresolved file merges or 'hg merge --abort' to abandon | |
|
236 | [1] | |
|
237 | $ ls | |
|
238 | x | |
|
239 | y | |
|
240 | z | |
|
241 | z.orig | |
|
242 | $ cat x | |
|
243 | x | |
|
244 | foo | |
|
245 | $ cat y | |
|
246 | y | |
|
247 | foo | |
|
248 | # 'z' should have had the added 'foo' line | |
|
249 | $ cat z | |
|
250 | <<<<<<< working copy: 07fcbc9a74ed - test: modify x, rename y to z | |
|
251 | y | |
|
252 | ||||||| base | |
|
253 | ======= | |
|
254 | x | |
|
255 | >>>>>>> merge rev: f21419739508 - test: modify y, rename x to z |
General Comments 0
You need to be logged in to leave comments.
Login now