Show More
@@ -318,20 +318,20 b' def _forgetremoved(wctx, mctx, branchmer' | |||||
318 | as removed. |
|
318 | as removed. | |
319 | """ |
|
319 | """ | |
320 |
|
320 | |||
321 |
|
|
321 | actions = {} | |
322 | factions = xactions = [] |
|
322 | m = 'f' | |
323 | if branchmerge: |
|
323 | if branchmerge: | |
324 | xactions = ractions |
|
324 | m = 'r' | |
325 | for f in wctx.deleted(): |
|
325 | for f in wctx.deleted(): | |
326 | if f not in mctx: |
|
326 | if f not in mctx: | |
327 |
|
|
327 | actions[f] = m, None, "forget deleted" | |
328 |
|
328 | |||
329 | if not branchmerge: |
|
329 | if not branchmerge: | |
330 | for f in wctx.removed(): |
|
330 | for f in wctx.removed(): | |
331 | if f not in mctx: |
|
331 | if f not in mctx: | |
332 |
|
|
332 | actions[f] = 'f', None, "forget removed" | |
333 |
|
333 | |||
334 |
return |
|
334 | return actions | |
335 |
|
335 | |||
336 | def _checkcollision(repo, wmf, actions): |
|
336 | def _checkcollision(repo, wmf, actions): | |
337 | # build provisional merged manifest up |
|
337 | # build provisional merged manifest up | |
@@ -617,17 +617,16 b' def calculateupdates(repo, wctx, mctx, a' | |||||
617 |
|
617 | |||
618 | _resolvetrivial(repo, wctx, mctx, ancestors[0], actions) |
|
618 | _resolvetrivial(repo, wctx, mctx, ancestors[0], actions) | |
619 |
|
619 | |||
|
620 | if wctx.rev() is None: | |||
|
621 | fractions = _forgetremoved(wctx, mctx, branchmerge) | |||
|
622 | actions.update(fractions) | |||
|
623 | ||||
620 | # Convert to dictionary-of-lists format |
|
624 | # Convert to dictionary-of-lists format | |
621 | actionbyfile = actions |
|
625 | actionbyfile = actions | |
622 | actions = dict((m, []) for m in 'a f g cd dc r dm dg m e k'.split()) |
|
626 | actions = dict((m, []) for m in 'a f g cd dc r dm dg m e k'.split()) | |
623 | for f, (m, args, msg) in actionbyfile.iteritems(): |
|
627 | for f, (m, args, msg) in actionbyfile.iteritems(): | |
624 | actions[m].append((f, args, msg)) |
|
628 | actions[m].append((f, args, msg)) | |
625 |
|
629 | |||
626 | if wctx.rev() is None: |
|
|||
627 | ractions, factions = _forgetremoved(wctx, mctx, branchmerge) |
|
|||
628 | actions['r'].extend(ractions) |
|
|||
629 | actions['f'].extend(factions) |
|
|||
630 |
|
||||
631 | return actions, diverge, renamedelete |
|
630 | return actions, diverge, renamedelete | |
632 |
|
631 | |||
633 | def batchremove(repo, actions): |
|
632 | def batchremove(repo, actions): |
General Comments 0
You need to be logged in to leave comments.
Login now