mercurial/archival.py
changeset 36139 b72c6ff4e4c0
parent 36036 788b2e8530ae
child 36437 745b0df08514
equal deleted inserted replaced
36138:a991fcc48222 36139:b72c6ff4e4c0
    16 import zlib
    16 import zlib
    17 
    17 
    18 from .i18n import _
    18 from .i18n import _
    19 
    19 
    20 from . import (
    20 from . import (
    21     cmdutil,
       
    22     error,
    21     error,
    23     formatter,
    22     formatter,
    24     match as matchmod,
    23     match as matchmod,
       
    24     scmutil,
    25     util,
    25     util,
    26     vfs as vfsmod,
    26     vfs as vfsmod,
    27 )
    27 )
    28 stringio = util.stringio
    28 stringio = util.stringio
    29 
    29 
   336     else:
   336     else:
   337         files = ctx.manifest().keys()
   337         files = ctx.manifest().keys()
   338     total = len(files)
   338     total = len(files)
   339     if total:
   339     if total:
   340         files.sort()
   340         files.sort()
   341         cmdutil._prefetchfiles(repo, ctx, files)
   341         scmutil.fileprefetchhooks(repo, ctx, files)
   342         repo.ui.progress(_('archiving'), 0, unit=_('files'), total=total)
   342         repo.ui.progress(_('archiving'), 0, unit=_('files'), total=total)
   343         for i, f in enumerate(files):
   343         for i, f in enumerate(files):
   344             ff = ctx.flags(f)
   344             ff = ctx.flags(f)
   345             write(f, 'x' in ff and 0o755 or 0o644, 'l' in ff, ctx[f].data)
   345             write(f, 'x' in ff and 0o755 or 0o644, 'l' in ff, ctx[f].data)
   346             repo.ui.progress(_('archiving'), i + 1, item=f,
   346             repo.ui.progress(_('archiving'), i + 1, item=f,