Show More
@@ -265,3 +265,78 b' Verify how the output looks and and how ' | |||||
265 | (branch merge, don't forget to commit) |
|
265 | (branch merge, don't forget to commit) | |
266 |
|
266 | |||
267 | $ cd .. |
|
267 | $ cd .. | |
|
268 | ||||
|
269 | http://stackoverflow.com/questions/9350005/how-do-i-specify-a-merge-base-to-use-in-a-hg-merge/9430810 | |||
|
270 | ||||
|
271 | $ hg init ancestor-merging | |||
|
272 | $ cd ancestor-merging | |||
|
273 | $ echo a > x | |||
|
274 | $ hg commit -A -m a x | |||
|
275 | $ hg update -q 0 | |||
|
276 | $ echo b >> x | |||
|
277 | $ hg commit -m b | |||
|
278 | $ hg update -q 0 | |||
|
279 | $ echo c >> x | |||
|
280 | $ hg commit -qm c | |||
|
281 | $ hg update -q 1 | |||
|
282 | $ hg merge -q --tool internal:local 2 | |||
|
283 | $ echo c >> x | |||
|
284 | $ hg commit -m bc | |||
|
285 | $ hg update -q 2 | |||
|
286 | $ hg merge -q --tool internal:local 1 | |||
|
287 | $ echo b >> x | |||
|
288 | $ hg commit -qm cb | |||
|
289 | ||||
|
290 | $ hg merge | |||
|
291 | note: using 70008a2163f6 as ancestor of 0d355fdef312 and 4b8b546a3eef | |||
|
292 | alternatively, use --config merge.preferancestor=b211bbc6eb3c | |||
|
293 | merging x | |||
|
294 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |||
|
295 | (branch merge, don't forget to commit) | |||
|
296 | $ cat x | |||
|
297 | a | |||
|
298 | c | |||
|
299 | b | |||
|
300 | c | |||
|
301 | ||||
|
302 | $ hg up -qC . | |||
|
303 | ||||
|
304 | $ hg merge --config merge.preferancestor=b211bbc6eb3c | |||
|
305 | note: using b211bbc6eb3c as ancestor of 0d355fdef312 and 4b8b546a3eef | |||
|
306 | alternatively, use --config merge.preferancestor=70008a2163f6 | |||
|
307 | merging x | |||
|
308 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |||
|
309 | (branch merge, don't forget to commit) | |||
|
310 | $ cat x | |||
|
311 | a | |||
|
312 | b | |||
|
313 | c | |||
|
314 | b | |||
|
315 | ||||
|
316 | $ hg up -qC . | |||
|
317 | ||||
|
318 | $ hg merge -v --config merge.preferancestor="*" | |||
|
319 | ||||
|
320 | calculating bids for ancestor 70008a2163f6 | |||
|
321 | resolving manifests | |||
|
322 | ||||
|
323 | calculating bids for ancestor b211bbc6eb3c | |||
|
324 | resolving manifests | |||
|
325 | ||||
|
326 | auction for merging merge bids | |||
|
327 | x: multiple merge bids: | |||
|
328 | x: m | |||
|
329 | x: m | |||
|
330 | x: ambiguous merge - picked m action) | |||
|
331 | end of auction | |||
|
332 | ||||
|
333 | merging x | |||
|
334 | 0 files updated, 1 files merged, 0 files removed, 0 files unresolved | |||
|
335 | (branch merge, don't forget to commit) | |||
|
336 | $ cat x | |||
|
337 | a | |||
|
338 | c | |||
|
339 | b | |||
|
340 | c | |||
|
341 | ||||
|
342 | $ cd .. |
General Comments 0
You need to be logged in to leave comments.
Login now