coffee, dart, elixir, elm: detect unclosed strings.
[jackhill/mal.git] / js / Makefile
CommitLineData
31690700 1
cc021efe 2TESTS = tests/types.js tests/reader.js
31690700 3
5245b079 4SOURCES_BASE = node_readline.js types.js reader.js printer.js interop.js
90f618cb 5SOURCES_LISP = env.js core.js stepA_mal.js
712af9ef 6SOURCES = $(SOURCES_BASE) $(SOURCES_LISP)
e4393504 7WEB_SOURCES = $(SOURCES:node_readline.js=jq_readline.js)
31690700 8
2a368ba6
JM
9STEPS = step0_repl.js step1_read_print.js step2_eval.js step3_env.js \
10 step4_if_fn_do.js step5_tco.js step6_file.js \
11 step7_quote.js step8_macros.js step9_try.js stepA_mal.js
12
5245b079
JM
13all: node_modules
14
8e2d4a4c 15dist: mal.js mal web/mal.js
e47ddca2
WB
16
17node_modules:
18 npm install
31690700 19
2a368ba6
JM
20$(STEPS): node_modules
21
31690700 22mal.js: $(SOURCES)
31690700 23 cat $+ | grep -v "= *require('./" >> $@
8e2d4a4c
JM
24
25mal: mal.js
26 echo "#!/usr/bin/env node" > $@
27 cat $< >> $@
31690700
JM
28 chmod +x $@
29
e4393504 30web/mal.js: $(WEB_SOURCES)
31690700
JM
31 cat $+ | grep -v "= *require('./" > $@
32
33clean:
e4393504 34 rm -f mal.js web/mal.js
2a368ba6 35 rm -rf node_modules
31690700 36
c4269f9b 37.PHONY: tests $(TESTS)
31690700
JM
38
39tests: $(TESTS)
40
41$(TESTS):
42 @echo "Running $@"; \
43 node $@ || exit 1; \