Merge spec and src lint targets
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -3,8 +3,7 @@
|
|||||||
/build/gh-pages
|
/build/gh-pages
|
||||||
/build/check-requires-timestamp
|
/build/check-requires-timestamp
|
||||||
/build/jsdoc-*-timestamp
|
/build/jsdoc-*-timestamp
|
||||||
/build/lint-spec-timestamp
|
/build/lint-timestamp
|
||||||
/build/lint-src-timestamp
|
|
||||||
/build/ol.css
|
/build/ol.css
|
||||||
/build/ol.js
|
/build/ol.js
|
||||||
/build/ol-all.js
|
/build/ol-all.js
|
||||||
|
|||||||
12
build.py
12
build.py
@@ -229,15 +229,15 @@ def serve_precommit(t):
|
|||||||
t.run('%(JAVA)s', '-jar', PLOVR_JAR, 'serve', 'build/ol-all.json', 'test/test.json')
|
t.run('%(JAVA)s', '-jar', PLOVR_JAR, 'serve', 'build/ol-all.json', 'test/test.json')
|
||||||
|
|
||||||
|
|
||||||
virtual('lint', 'build/lint-src-timestamp', 'build/lint-spec-timestamp', 'build/check-requires-timestamp')
|
virtual('lint', 'build/lint-timestamp', 'build/check-requires-timestamp')
|
||||||
|
|
||||||
|
|
||||||
@target('build/lint-src-timestamp', SRC, INTERNAL_SRC, EXTERNAL_SRC, EXAMPLES_SRC, precious=True)
|
@target('build/lint-timestamp', SRC, INTERNAL_SRC, EXTERNAL_SRC, EXAMPLES_SRC, SPEC, precious=True)
|
||||||
def build_lint_src_timestamp(t):
|
def build_lint_src_timestamp(t):
|
||||||
limited_doc_files = [path
|
limited_doc_files = [path
|
||||||
for path in ifind('externs', 'build/src/external/externs')
|
for path in ifind('externs', 'build/src/external/externs')
|
||||||
if path.endswith('.js')]
|
if path.endswith('.js')]
|
||||||
t.run('%(GJSLINT)s', '--strict', '--limited_doc_files=%s' % (','.join(limited_doc_files),), t.newer(SRC, INTERNAL_SRC, EXTERNAL_SRC, EXAMPLES_SRC))
|
t.run('%(GJSLINT)s', '--strict', '--limited_doc_files=%s' % (','.join(limited_doc_files),), t.newer(t.dependencies))
|
||||||
t.touch()
|
t.touch()
|
||||||
|
|
||||||
|
|
||||||
@@ -331,12 +331,6 @@ def build_check_requires_timestamp(t):
|
|||||||
t.touch()
|
t.touch()
|
||||||
|
|
||||||
|
|
||||||
@target('build/lint-spec-timestamp', SPEC, precious=True)
|
|
||||||
def build_lint_spec_timestamp(t):
|
|
||||||
t.run('%(GJSLINT)s', '--strict', t.newer(SPEC))
|
|
||||||
t.touch()
|
|
||||||
|
|
||||||
|
|
||||||
virtual('plovr', PLOVR_JAR)
|
virtual('plovr', PLOVR_JAR)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user