Lines Matching refs:ext
46 head, ext = os.path.splitext(filename)
48 if ext == base:
49 ext = "" # E.g. .cvsignore is deemed not to have an extension
50 ext = os.path.normcase(ext)
51 if not ext:
52 ext = "<none>"
53 self.addstats(ext, "files", 1)
59 self.addstats(ext, "unopenable", 1)
61 self.addstats(ext, "bytes", len(data))
63 self.addstats(ext, "binary", 1)
66 self.addstats(ext, "empty", 1)
69 self.addstats(ext, "lines", len(lines))
72 self.addstats(ext, "words", len(words))
74 def addstats(self, ext, key, n): argument
75 d = self.stats.setdefault(ext, {})
82 for ext in exts:
83 columns.update(self.stats[ext])
92 for ext in exts:
93 value = self.stats[ext].get(col)
104 for ext in exts:
105 self.stats[ext]["ext"] = ext
114 for ext in exts:
116 value = self.stats[ext].get(col, "")