Download:
child 195:31c88aa3a6d2
parent 193:9c3b5aeb722c
194:7dab4b84d205
Anton Shestakov <av6@dwimlabs.net>, Sat, 30 Jul 2016 16:11:32 +0800
checker: show version of each installed linter, even if it didn't need setup

1 файлов изменено, 8 вставок(+), 5 удалений(-) [+]
checker.py file | annotate | diff | comparison | revisions
--- a/checker.py Sat Jul 30 13:48:34 2016 +0800
+++ b/checker.py Sat Jul 30 16:11:32 2016 +0800
@@ -267,16 +267,19 @@
lc = process_config(linter_config[name], linter)
- if 'setup' in lc and str(lc['setup']) not in setup_cache:
- for item in lc['setup']:
- if not run(item):
- return False
- setup_cache.add(str(lc['setup']))
+ key = (name, str(lc.get('setup', [])))
+ if key in setup_cache:
+ continue
+
+ for item in lc.get('setup', []):
+ if not run(item):
+ return False
if 'version' in lc:
if not run(lc['exec'] + lc['version'], env=lc['env']):
return False
+ setup_cache.add(key)
if name not in installed:
installed.append(name)