453 audit(f) |
453 audit(f) |
454 util.unlinkpath(repo.wjoin(f)) |
454 util.unlinkpath(repo.wjoin(f)) |
455 |
455 |
456 numupdates = len(actions) |
456 numupdates = len(actions) |
457 workeractions = [a for a in actions if a[1] in 'gr'] |
457 workeractions = [a for a in actions if a[1] in 'gr'] |
458 updated = len([a for a in workeractions if a[1] == 'g']) |
458 updateactions = [a for a in workeractions if a[1] == 'g'] |
459 removed = len([a for a in workeractions if a[1] == 'r']) |
459 updated = len(updateactions) |
|
460 removeactions = [a for a in workeractions if a[1] == 'r'] |
|
461 removed = len(removeactions) |
460 actions = [a for a in actions if a[1] not in 'gr'] |
462 actions = [a for a in actions if a[1] not in 'gr'] |
461 |
463 |
462 hgsub = [a[1] for a in workeractions if a[0] == '.hgsubstate'] |
464 hgsub = [a[1] for a in workeractions if a[0] == '.hgsubstate'] |
463 if hgsub and hgsub[0] == 'r': |
465 if hgsub and hgsub[0] == 'r': |
464 subrepo.submerge(repo, wctx, mctx, wctx, overwrite) |
466 subrepo.submerge(repo, wctx, mctx, wctx, overwrite) |
465 |
467 |
466 z = 0 |
468 z = 0 |
467 prog = worker.worker(repo.ui, 0.001, getremove, (repo, mctx, overwrite), |
469 prog = worker.worker(repo.ui, 0.001, getremove, (repo, mctx, overwrite), |
468 workeractions) |
470 removeactions) |
|
471 for i, item in prog: |
|
472 z += i |
|
473 repo.ui.progress(_('updating'), z, item=item, total=numupdates, |
|
474 unit=_('files')) |
|
475 prog = worker.worker(repo.ui, 0.001, getremove, (repo, mctx, overwrite), |
|
476 updateactions) |
469 for i, item in prog: |
477 for i, item in prog: |
470 z += i |
478 z += i |
471 repo.ui.progress(_('updating'), z, item=item, total=numupdates, |
479 repo.ui.progress(_('updating'), z, item=item, total=numupdates, |
472 unit=_('files')) |
480 unit=_('files')) |
473 |
481 |