mercurial/commands.py
changeset 37438 7b7ca9ba2de5
parent 37437 814e080a1215
child 37479 d665b4ea7d4c
equal deleted inserted replaced
37437:814e080a1215 37438:7b7ca9ba2de5
  3489 
  3489 
  3490     if opts.get('all'):
  3490     if opts.get('all'):
  3491         if rev or node:
  3491         if rev or node:
  3492             raise error.Abort(_("can't specify a revision with --all"))
  3492             raise error.Abort(_("can't specify a revision with --all"))
  3493 
  3493 
  3494         res = []
  3494         res = set()
  3495         # TODO this is a massive layering violation. It assumes the repo is
  3495         for rev in repo:
  3496         # backed by revlogs with a well-defined naming scheme.
  3496             ctx = repo[rev]
  3497         prefix = "data/"
  3497             res |= set(ctx.files())
  3498         suffix = ".i"
  3498 
  3499         plen = len(prefix)
       
  3500         slen = len(suffix)
       
  3501         with repo.lock():
       
  3502             for fn, b, size in repo.store.datafiles():
       
  3503                 if size != 0 and fn[-slen:] == suffix and fn[:plen] == prefix:
       
  3504                     res.append(fn[plen:-slen])
       
  3505         ui.pager('manifest')
  3499         ui.pager('manifest')
  3506         for f in res:
  3500         for f in sorted(res):
  3507             fm.startitem()
  3501             fm.startitem()
  3508             fm.write("path", '%s\n', f)
  3502             fm.write("path", '%s\n', f)
  3509         fm.end()
  3503         fm.end()
  3510         return
  3504         return
  3511 
  3505