Plugins/CheckerPlugins/SyntaxChecker/SyntaxCheckerDialog.py

changeset 28
dde24fc7f7ba
parent 13
1af94a91f439
child 40
c2e5472b112c
equal deleted inserted replaced
27:1018a0347ae9 28:dde24fc7f7ba
75 If this is given, file must be a single file name. 75 If this is given, file must be a single file name.
76 """ 76 """
77 if isinstance(fn, list): 77 if isinstance(fn, list):
78 files = fn 78 files = fn
79 elif os.path.isdir(fn): 79 elif os.path.isdir(fn):
80 # TODO: make this dependant on configured extensions
80 files = Utilities.direntries(fn, 1, '*.py', 0) 81 files = Utilities.direntries(fn, 1, '*.py', 0)
81 files += Utilities.direntries(fn, 1, '*.pyw', 0) 82 files += Utilities.direntries(fn, 1, '*.pyw', 0)
82 files += Utilities.direntries(fn, 1, '*.ptl', 0) 83 files += Utilities.direntries(fn, 1, '*.ptl', 0)
83 else: 84 else:
84 files = [fn] 85 files = [fn]
86 # TODO: make this dependant on configured extensions
85 files = [f for f in files \ 87 files = [f for f in files \
86 if f.endswith(".py") or f.endswith(".pyw") or f.endswith(".ptl")] 88 if f.endswith(".py") or f.endswith(".pyw") or f.endswith(".ptl")]
87 89
88 if (codestring and len(files) == 1) or \ 90 if (codestring and len(files) == 1) or \
89 (not codestring and len(files) > 0): 91 (not codestring and len(files) > 0):

eric ide

mercurial