diff mercurial/commands.py @ 6749:51b0e799352f

manifest: remove execf/linkf methods
author Matt Mackall <mpm@selenic.com>
date Thu, 26 Jun 2008 14:35:50 -0500
parents c6cc35a3d1de
children fb42030d79d6
line wrap: on
line diff
--- a/mercurial/commands.py	Thu Jun 26 14:35:50 2008 -0500
+++ b/mercurial/commands.py	Thu Jun 26 14:35:50 2008 -0500
@@ -1866,17 +1866,13 @@
     if not node:
         node = rev
 
-    m = repo[node].manifest()
-    files = m.keys()
-    files.sort()
-
-    for f in files:
+    decor = {'l':'644 @ ', 'x':'755 * ', '':'644   '}
+    ctx = repo[node]
+    for f in ctx:
         if ui.debugflag:
-            ui.write("%40s " % hex(m[f]))
+            ui.write("%40s " % hex(ctx.manifest()[f]))
         if ui.verbose:
-            type = m.execf(f) and "*" or m.linkf(f) and "@" or " "
-            perm = m.execf(f) and "755" or "644"
-            ui.write("%3s %1s " % (perm, type))
+            ui.write(decor[ctx.flags(f)])
         ui.write("%s\n" % f)
 
 def merge(ui, repo, node=None, force=None, rev=None):