--- a/contrib/shrink-revlog.py Wed Mar 28 11:42:17 2012 +0200
+++ b/contrib/shrink-revlog.py Wed Mar 28 15:15:15 2012 -0400
@@ -16,7 +16,7 @@
# e.g. by comparing "before" and "after" states of random changesets
# (maybe: export before, shrink, export after, diff).
-import os, tempfile, errno
+import os, errno
from mercurial import revlog, transaction, node, util, scmutil
from mercurial import changegroup
from mercurial.i18n import _
@@ -191,7 +191,6 @@
'will corrupt your repository'))
ui.write(_('shrinking %s\n') % indexfn)
- prefix = os.path.basename(indexfn)[:-1]
tmpindexfn = util.mktempcopy(indexfn, emptyok=True)
r1 = revlog.revlog(scmutil.opener(os.getcwd(), audit=False), indexfn)