UNPKG

726 BPlain TextView Raw
1BUNYAN_LEVEL?=1000
2SHELL = /bin/bash -o pipefail
3
4all: install test
5
6check: install
7 ./node_modules/.bin/eslint src/
8 ./node_modules/.bin/coffeelint -q src tests
9
10test: check
11 ./node_modules/.bin/mocha -b --recursive --compilers coffee:coffee-script/register tests | ./node_modules/.bin/bunyan -l ${BUNYAN_LEVEL}
12
13coverage: test
14 @mkdir -p doc
15 ./node_modules/.bin/istanbul cover --dir doc ./node_modules/.bin/_mocha -- --recursive --compilers coffee:coffee-script/register tests
16 @echo "coverage exported to doc/lcov-report/index.html"
17
18run: check
19 node index.js | ./node_modules/.bin/bunyan -l ${BUNYAN_LEVEL}
20
21install: node_modules
22
23node_modules: package.json
24 npm install
25 @touch node_modules
26
27clean:
28 rm -fr node_modules