Show More
@@ -1464,6 +1464,34 b' def update(repo, node, branchmerge, forc' | |||
|
1464 | 1464 | actionbyfile, diverge, renamedelete = calculateupdates( |
|
1465 | 1465 | repo, wc, p2, pas, branchmerge, force, mergeancestor, |
|
1466 | 1466 | followcopies, matcher=matcher) |
|
1467 | ||
|
1468 | # Prompt and create actions. Most of this is in the resolve phase | |
|
1469 | # already, but we can't handle .hgsubstate in filemerge or | |
|
1470 | # subrepo.submerge yet so we have to keep prompting for it. | |
|
1471 | if '.hgsubstate' in actionbyfile: | |
|
1472 | f = '.hgsubstate' | |
|
1473 | m, args, msg = actionbyfile[f] | |
|
1474 | if m == 'cd': | |
|
1475 | if repo.ui.promptchoice( | |
|
1476 | _("local changed %s which remote deleted\n" | |
|
1477 | "use (c)hanged version or (d)elete?" | |
|
1478 | "$$ &Changed $$ &Delete") % f, 0): | |
|
1479 | actionbyfile[f] = ('r', None, "prompt delete") | |
|
1480 | elif f in p1: | |
|
1481 | actionbyfile[f] = ('am', None, "prompt keep") | |
|
1482 | else: | |
|
1483 | actionbyfile[f] = ('a', None, "prompt keep") | |
|
1484 | elif m == 'dc': | |
|
1485 | f1, f2, fa, move, anc = args | |
|
1486 | flags = p2[f2].flags() | |
|
1487 | if repo.ui.promptchoice( | |
|
1488 | _("remote changed %s which local deleted\n" | |
|
1489 | "use (c)hanged version or leave (d)eleted?" | |
|
1490 | "$$ &Changed $$ &Deleted") % f, 0) == 0: | |
|
1491 | actionbyfile[f] = ('g', (flags, False), "prompt recreating") | |
|
1492 | else: | |
|
1493 | del actionbyfile[f] | |
|
1494 | ||
|
1467 | 1495 | # Convert to dictionary-of-lists format |
|
1468 | 1496 | actions = dict((m, []) for m in 'a am f g cd dc r dm dg m e k'.split()) |
|
1469 | 1497 | for f, (m, args, msg) in actionbyfile.iteritems(): |
@@ -1479,33 +1507,6 b' def update(repo, node, branchmerge, forc' | |||
|
1479 | 1507 | else: |
|
1480 | 1508 | _checkcollision(repo, wc.manifest(), actions) |
|
1481 | 1509 | |
|
1482 | # Prompt and create actions. Most of this is in the resolve phase | |
|
1483 | # already, but we can't handle .hgsubstate in filemerge or | |
|
1484 | # subrepo.submerge yet so we have to keep prompting for it. | |
|
1485 | for f, args, msg in sorted(actions['cd']): | |
|
1486 | if f != '.hgsubstate': | |
|
1487 | continue | |
|
1488 | if repo.ui.promptchoice( | |
|
1489 | _("local changed %s which remote deleted\n" | |
|
1490 | "use (c)hanged version or (d)elete?" | |
|
1491 | "$$ &Changed $$ &Delete") % f, 0): | |
|
1492 | actions['r'].append((f, None, "prompt delete")) | |
|
1493 | elif f in p1: | |
|
1494 | actions['am'].append((f, None, "prompt keep")) | |
|
1495 | else: | |
|
1496 | actions['a'].append((f, None, "prompt keep")) | |
|
1497 | ||
|
1498 | for f, args, msg in sorted(actions['dc']): | |
|
1499 | if f != '.hgsubstate': | |
|
1500 | continue | |
|
1501 | f1, f2, fa, move, anc = args | |
|
1502 | flags = p2[f2].flags() | |
|
1503 | if repo.ui.promptchoice( | |
|
1504 | _("remote changed %s which local deleted\n" | |
|
1505 | "use (c)hanged version or leave (d)eleted?" | |
|
1506 | "$$ &Changed $$ &Deleted") % f, 0) == 0: | |
|
1507 | actions['g'].append((f, (flags, False), "prompt recreating")) | |
|
1508 | ||
|
1509 | 1510 | # divergent renames |
|
1510 | 1511 | for f, fl in sorted(diverge.iteritems()): |
|
1511 | 1512 | repo.ui.warn(_("note: possible conflict - %s was renamed " |
General Comments 0
You need to be logged in to leave comments.
Login now