740 if os.path.lexists(repo.wjoin(f)): |
740 if os.path.lexists(repo.wjoin(f)): |
741 repo.ui.debug("removing %s\n" % f) |
741 repo.ui.debug("removing %s\n" % f) |
742 audit(f) |
742 audit(f) |
743 util.unlinkpath(repo.wjoin(f)) |
743 util.unlinkpath(repo.wjoin(f)) |
744 |
744 |
745 numupdates = sum(len(l) for m, l in actions.items() if m != 'k') |
745 numupdates = sum(len(l) for m, l in actions.items() |
|
746 if m not in ('k', 'dr', 'rd')) |
746 |
747 |
747 if [a for a in actions['r'] if a[0] == '.hgsubstate']: |
748 if [a for a in actions['r'] if a[0] == '.hgsubstate']: |
748 subrepo.submerge(repo, wctx, mctx, wctx, overwrite) |
749 subrepo.submerge(repo, wctx, mctx, wctx, overwrite) |
749 |
750 |
750 # remove in parallel (must come first) |
751 # remove in parallel (must come first) |
823 repo.wwrite(f, mctx.filectx(f0).data(), flags) |
824 repo.wwrite(f, mctx.filectx(f0).data(), flags) |
824 updated += 1 |
825 updated += 1 |
825 |
826 |
826 # divergent renames |
827 # divergent renames |
827 for f, args, msg in actions['dr']: |
828 for f, args, msg in actions['dr']: |
828 repo.ui.debug(" %s: %s -> dr\n" % (f, msg)) |
|
829 z += 1 |
|
830 progress(_updating, z, item=f, total=numupdates, unit=_files) |
|
831 fl, = args |
829 fl, = args |
832 repo.ui.warn(_("note: possible conflict - %s was renamed " |
830 repo.ui.warn(_("note: possible conflict - %s was renamed " |
833 "multiple times to:\n") % f) |
831 "multiple times to:\n") % f) |
834 for nf in fl: |
832 for nf in fl: |
835 repo.ui.warn(" %s\n" % nf) |
833 repo.ui.warn(" %s\n" % nf) |
836 |
834 |
837 # rename and delete |
835 # rename and delete |
838 for f, args, msg in actions['rd']: |
836 for f, args, msg in actions['rd']: |
839 repo.ui.debug(" %s: %s -> rd\n" % (f, msg)) |
|
840 z += 1 |
|
841 progress(_updating, z, item=f, total=numupdates, unit=_files) |
|
842 fl, = args |
837 fl, = args |
843 repo.ui.warn(_("note: possible conflict - %s was deleted " |
838 repo.ui.warn(_("note: possible conflict - %s was deleted " |
844 "and renamed to:\n") % f) |
839 "and renamed to:\n") % f) |
845 for nf in fl: |
840 for nf in fl: |
846 repo.ui.warn(" %s\n" % nf) |
841 repo.ui.warn(" %s\n" % nf) |