diff hgext/churn.py @ 45720:508dfd1c18df

scmutil: move walkchangerevs() from cmdutil It's no longer a command-level function, but a pure helper to walk revisions in a windowed way. This change will help eliminate reverse dependency of revset.py -> grep.py -> cmdutil.py in future patches.
author Yuya Nishihara <yuya@tcha.org>
date Sun, 04 Oct 2020 13:17:57 +0900
parents d1759b2e1888
children 89a2afe31e82
line wrap: on
line diff
--- a/hgext/churn.py	Wed Sep 09 17:04:44 2020 +0900
+++ b/hgext/churn.py	Sun Oct 04 13:17:57 2020 +0900
@@ -23,6 +23,7 @@
     patch,
     pycompat,
     registrar,
+    scmutil,
 )
 
 cmdtable = {}
@@ -98,7 +99,7 @@
         exclude_pats=opts[b'exclude'],
     )
     revs, makefilematcher = logcmdutil.makewalker(repo, wopts)
-    for ctx in cmdutil.walkchangerevs(repo, revs, makefilematcher, prep):
+    for ctx in scmutil.walkchangerevs(repo, revs, makefilematcher, prep):
         continue
 
     progress.complete()