-
Notifications
You must be signed in to change notification settings - Fork 5
/
Makefile
38 lines (27 loc) · 856 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
STATIC=public/*.html public/*.png public/*.css public/*.svg public/*.gif public/content
all: server.js build
server.js: src/**/*.cljs shadow-cljs.edn node_modules
npx shadow-cljs release server --debug
test.js: src/**/*.cljs shadow-cljs.edn node_modules
npx shadow-cljs release tests
build: src/**/* $(STATIC) node_modules
mkdir -p build
cp -LR --preserve=all $(STATIC) build
npx shadow-cljs release app
touch build
node_modules: package.json
pnpm i --no-lockfile --shamefully-hoist
touch node_modules
test: test.js
node test.js
.PHONY: watch watcher server repl
server:
rm -f devserver.js
until [ -f devserver.js ]; do sleep 1; done
sleep 1 && while [ 1 ]; do node devserver.js; sleep 3; done
watcher: src/**/*.cljs node_modules
npx shadow-cljs watch server app
watch:
make -j2 watcher server
repl:
npx shadow-cljs cljs-repl app