depth: fix compare mode for `debugdepth`
The compare mode was broken for silly reasons.
--- a/hgext3rd/evolve/depthcache.py Fri Dec 15 10:14:42 2017 +0100
+++ b/hgext3rd/evolve/depthcache.py Sun Dec 17 21:17:28 2017 +0100
@@ -36,7 +36,7 @@
"""
revs = scmutil.revrange(repo, opts['rev'])
method = opts['method']
- if method == 'cached':
+ if method in ('cached', 'compare'):
cache = repo.depthcache
cache.save(repo)
for r in revs:
@@ -51,6 +51,7 @@
if simple != cached:
raise error.Abort('depth differ for revision %s: %d != %d'
% (ctx, simple, cached))
+ depth = simple
else:
raise error.Abort('unknown method "%s"' % method)
ui.write('%s %d\n' % (ctx, depth))