##// END OF EJS Templates
merge: collect checking for unknown files at end of manifestmerge()...
Martin von Zweigbergk -
r23651:72da02d7 default
parent child Browse files
Show More
@@ -401,7 +401,6 b' def manifestmerge(repo, wctx, p2, pa, br'
401 401 m1['.hgsubstate'] += '+'
402 402 break
403 403
404 aborts = []
405 404 # Compare manifests
406 405 diff = m1.diff(m2)
407 406
@@ -488,8 +487,7 b' def manifestmerge(repo, wctx, p2, pa, br'
488 487 # following table:
489 488 #
490 489 # force branchmerge different | action
491 # n * n | create
492 # n * y | abort
490 # n * * | create
493 491 # y n * | create
494 492 # y y n | create
495 493 # y y y | merge
@@ -497,11 +495,7 b' def manifestmerge(repo, wctx, p2, pa, br'
497 495 # Checking whether the files are different is expensive, so we
498 496 # don't do that when we can avoid it.
499 497 if not force:
500 different = _checkunknownfile(repo, wctx, p2, f)
501 if different:
502 aborts.append((f, "ud"))
503 else:
504 actions[f] = ('c', (fl2,), "remote created")
498 actions[f] = ('c', (fl2,), "remote created")
505 499 elif not branchmerge:
506 500 actions[f] = ('c', (fl2,), "remote created")
507 501 else:
@@ -512,14 +506,17 b' def manifestmerge(repo, wctx, p2, pa, br'
512 506 else:
513 507 actions[f] = ('g', (fl2,), "remote created")
514 508 elif n2 != ma[f]:
515 different = _checkunknownfile(repo, wctx, p2, f)
516 if not force and different:
517 aborts.append((f, 'ud'))
509 if acceptremote:
510 actions[f] = ('c', (fl2,), "remote recreating")
518 511 else:
519 if acceptremote:
520 actions[f] = ('c', (fl2,), "remote recreating")
521 else:
522 actions[f] = ('dc', (fl2,), "prompt deleted/changed")
512 actions[f] = ('dc', (fl2,), "prompt deleted/changed")
513
514 aborts = []
515 if not force:
516 for f, (m, args, msg) in actions.iteritems():
517 if m in ('c', 'dc'):
518 if _checkunknownfile(repo, wctx, p2, f):
519 aborts.append((f, "ud"))
523 520
524 521 for f, m in sorted(aborts):
525 522 if m == 'ud':
General Comments 0
You need to be logged in to leave comments. Login now