-
Notifications
You must be signed in to change notification settings - Fork 17
/
Copy pathMakefile
38 lines (28 loc) · 802 Bytes
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
SRC_FILES=
SRC_FILES+= src/*.js
SRC_FILES+= src/**/*.js
SRC_FILES+= src/**/**/*.js
SRC_FILES+= src/**/**/**/*.js
SRC_FILES+= bin/gyp
SRC_FILES+= test/*.js
SRC_FILES+= test/**/*.js
SRC_FILES+= test/**/**/*.js
BINDIR=./node_modules/.bin
COVERAGEDIR=./coverage
build:
@$(BINDIR)/babel src -d lib
build-watch:
@$(BINDIR)/babel -w src -d lib
lint:
@$(BINDIR)/eslint $(SRC_FILES)
format:
@$(BINDIR)/eslint --fix $(SRC_FILES)
check: build
@$(BINDIR)/mocha --reporter=spec test/*-test.js --compilers js:babel-register
coverage:
@-rm -rf $(COVERAGEDIR)
@$(BINDIR)/istanbul cover --report none --print none --include-pid \
$(BINDIR)/_mocha -- -u exports -R spec test/*-test.js
@$(BINDIR)/istanbul report text-summary lcov
test: check
.PHONY: build build-watch lint format check test coverage