[PATCH 1 of 3] archival: construct progress helper through ui.makeprogress()

Yuya Nishihara yuya at tcha.org
Sun Jan 13 06:43:09 UTC 2019


# HG changeset patch
# User Yuya Nishihara <yuya at tcha.org>
# Date 1547357171 -32400
#      Sun Jan 13 14:26:11 2019 +0900
# Node ID ec7bc9f70e3982f30c2801d3af51d57c498b0851
# Parent  3f807237dc94925b7f92aeb6a822440856cc8b47
archival: construct progress helper through ui.makeprogress()

No idea why we didn't.

diff --git a/mercurial/archival.py b/mercurial/archival.py
--- a/mercurial/archival.py
+++ b/mercurial/archival.py
@@ -327,8 +327,8 @@ def archive(repo, dest, node, kind, deco
         files.sort()
         scmutil.prefetchfiles(repo, [ctx.rev()],
                               scmutil.matchfiles(repo, files))
-        progress = scmutil.progress(repo.ui, _('archiving'), unit=_('files'),
-                                    total=total)
+        progress = repo.ui.makeprogress(_('archiving'), unit=_('files'),
+                                        total=total)
         progress.update(0)
         for f in files:
             ff = ctx.flags(f)


More information about the Mercurial-devel mailing list