Run lint on specs
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -1,5 +1,6 @@
|
||||
/bin/plovr*.jar
|
||||
/build/lint-timestamp
|
||||
/build/lint-spec-timestamp
|
||||
/build/lint-src-timestamp
|
||||
/build/ol.js
|
||||
/build/ol-all.js
|
||||
/build/proj4js-combined.js
|
||||
|
||||
11
Makefile
11
Makefile
@@ -1,6 +1,7 @@
|
||||
JSDOC = jsdoc
|
||||
PHANTOMJS = phantomjs
|
||||
PLOVR_JAR = bin/plovr-b254c26318c5.jar
|
||||
SPEC = $(shell find test/spec -name \*.js)
|
||||
SRC = $(shell find exports externs src/ol -name \*.js)
|
||||
TARGETS = $(shell find demos -name advanced-optimizations.js)
|
||||
comma := ,
|
||||
@@ -104,11 +105,14 @@ serve: $(PLOVR_JAR) build/require-all.js
|
||||
java -jar $(PLOVR_JAR) serve build/*.json demos/*/*.json
|
||||
|
||||
.PHONY: lint
|
||||
lint: build/lint-timestamp
|
||||
lint: build/lint-src-timestamp build/lint-spec-timestamp
|
||||
|
||||
build/lint-timestamp: $(SRC)
|
||||
build/lint-src-timestamp: $(SRC)
|
||||
gjslint --strict --limited_doc_files=$(subst $(space),$(comma),$(shell find externs -name \*.js)) $(SRC) $(filter-out $(TARGETS),$(shell find demos -name \*.js)) && touch $@
|
||||
|
||||
build/lint-spec-timestamp: $(SPEC)
|
||||
gjslint $(SPEC) && touch $@
|
||||
|
||||
.PHONY: plovr
|
||||
plovr: $(PLOVR_JAR)
|
||||
|
||||
@@ -125,7 +129,8 @@ test:
|
||||
$(PHANTOMJS) test/phantom-jasmine/run_jasmine_test.coffee test/ol.html
|
||||
|
||||
clean:
|
||||
rm -f build/lint-timestamp
|
||||
rm -f build/lint-spec-timestamp
|
||||
rm -f build/lint-src-timestamp
|
||||
rm -f build/ol.js
|
||||
rm -f build/ol-all.js
|
||||
rm -f build/require-all.js
|
||||
|
||||
Reference in New Issue
Block a user