forked from emarschner/iconify
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
55 lines (35 loc) · 1.13 KB
/
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
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
export SHELL=./make-env.sh
init:
npm install
dist-dir:
@mkdir -p dist
dist: init dist-dir $(shell find src -name *.js)
browserify src/browser/index.js -t browserify-shim -s iconify > dist/iconify.js
.PHONY: node-test browser-test amd-test test
node-test: init
mocha tests/*-test.js tests/node
browser-test: init
karma start tests/browser/karma.conf.js --single-run $(KARMA_FLAGS)
amd-test: init
karma start tests/amd/karma.conf.js --single-run $(KARMA_FLAGS)
test: amd-test browser-test node-test
.PHONY: node-coverage browser-coverage coverage
node-coverage: init
istanbul cover node_modules/.bin/_mocha -- tests/*-test.js tests/node
browser-coverage: init
karma start tests/browser/karma.coverage-conf.js --single-run $(KARMA_FLAGS)
coverage: browser-coverage node-coverage
.PHONY: clean-coverage clean-dist clean-examples clean-package clean
clean-coverage:
-rm -rf coverage/
clean-dist:
-rm -rf dist/
clean-examples:
-cd examples/; make clean
clean-package:
-rm -rf package/ *.tgz
clean: clean-coverage clean-dist clean-examples clean-package
-rm -rf node_modules/
.PHONY: examples
examples: dist
cd examples/; make