diff contrib/shrink-revlog.py @ 13782:9131724c3f4b

changegroup: combine infocollect and lookup callbacks
author Matt Mackall <mpm@selenic.com>
date Mon, 28 Mar 2011 11:18:56 -0500
parents 4c50552fc9bc
children c196352d935b
line wrap: on
line diff
--- a/contrib/shrink-revlog.py	Thu Mar 24 17:16:30 2011 -0500
+++ b/contrib/shrink-revlog.py	Mon Mar 28 11:18:56 2011 -0500
@@ -110,7 +110,10 @@
     order = [r1.node(r) for r in order]
 
     # this is a bit ugly, but it works
-    lookup = lambda x: "%020d" % r1.linkrev(r1.rev(x))
+    def lookup(x):
+        progress(x)
+        return "%020d" % r1.linkrev(r1.rev(x))
+
     unlookup = lambda x: int(x, 10)
 
     try: