changeset 13650:56e71e7d2ba2

eol: no need to accumulate files when checking all changesets Just check the files touched by the changesets.
author Patrick Mezard <pmezard@gmail.com>
date Mon, 14 Mar 2011 21:31:54 +0100
parents 328ce8a405ac
children 0652b2da832d
files hgext/eol.py
diffstat 1 files changed, 3 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/hgext/eol.py	Mon Mar 14 21:08:18 2011 +0100
+++ b/hgext/eol.py	Mon Mar 14 21:31:54 2011 +0100
@@ -170,7 +170,7 @@
 
     def checkrev(self, repo, ctx, files):
         failed = []
-        for f in files:
+        for f in (files or ctx.files()):
             if f not in ctx:
                 continue
             for pattern, style in self.cfg.items('patterns'):
@@ -207,10 +207,10 @@
     files = set()
     revs = set()
     for rev in xrange(repo[node].rev(), len(repo)):
-        ctx = repo[rev]
-        files.update(ctx.files())
         revs.add(rev)
         if headsonly:
+            ctx = repo[rev]
+            files.update(ctx.files())
             for pctx in ctx.parents():
                 revs.discard(pctx.rev())
     failed = []