Since we can rely on map files to have a .map extension now,

...simplify a test a bit and remove an explicit list of exception
extensions.
This commit is contained in:
Eric S. Raymond 2008-09-04 18:17:24 +00:00
parent d3e819dd22
commit 2d07184bc9

View file

@ -1052,14 +1052,11 @@ def translator(filename, mapxforms, textxform):
else:
return None
ignore = (".tgz", ".png", ".jpg", "-bak")
vctypes = (".svn", ".git")
def interesting(fn):
"Is a file interesting for conversion purposes?"
return fn.endswith(".cfg") or fn.endswith(".map") \
or ("maps" in fn and fn[-4:] not in ignore) \
or is_map(fn)
return fn.endswith(".cfg") or is_map(fn)
def allcfgfiles(dir):
"Get the names of all interesting files under dir."