forked from processing-js/processing-js
-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathMakefile
More file actions
53 lines (38 loc) · 1.47 KB
/
Makefile
File metadata and controls
53 lines (38 loc) · 1.47 KB
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
# If your jsshell isn't at ./tools/js/src/js, update JS below
TOOLSDIR=./tools
JS=$(TOOLSDIR)/js/src/js
# Rule for making pure JS code from a .pde (runs through parser + beautify)
%.js : %.pde
$(TOOLSDIR)/pde2js.py $(JS) $?
all: release
create-release: clean
mkdir ./release
release: pretty packed minified
pretty: create-release
$(TOOLSDIR)/jsbeautify.py $(JS) processing.js > ./release/processing.js
# check for any parsing errors in pretty version of processing.js
$(JS) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing.js
packed: create-release
$(TOOLSDIR)/packer.py $(JS) processing.js > ./release/processing-packed.js
# check for any parsing errors in packed version of processing.js
$(JS) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing-packed.js
minified: create-release
$(TOOLSDIR)/minifier.py $(JS) processing.js > ./release/processing-min.js
# check for any parsing errors in minified version of processing.js
$(JS) -f $(TOOLSDIR)/fake-dom.js -f ./release/processing-min.js
check:
$(TOOLSDIR)/runtests.py $(JS)
check-summary:
$(TOOLSDIR)/runtests.py $(JS) | grep "^TEST SUMMARY"
check-lint:
$(TOOLSDIR)/jslint.py $(JS) processing.js
check-parser:
$(TOOLSDIR)/runtests.py -p $(JS)
check-unit:
$(TOOLSDIR)/runtests.py -u $(JS)
# If you want to test just one file or dir, use |make check-one TEST=<file or dir>|
TEST ?= $(error Specify a test filename/dir in TEST when using check-test)
check-one:
$(TOOLSDIR)/runtests.py $(JS) -t $(TEST)
clean:
rm -fr ./release