-
Notifications
You must be signed in to change notification settings - Fork 8
Expand file tree
/
Copy pathMakefile
More file actions
36 lines (28 loc) · 747 Bytes
/
Makefile
File metadata and controls
36 lines (28 loc) · 747 Bytes
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
web-files := $(shell find . \( -name '*.css' -o -name '*.html' -o -name '*.mjs' \) -print)
biome := NODE_NO_WARNINGS=1 npx --yes @biomejs/biome@2.4.12 check --config-path=.biome.json
.PHONY: format
format: .git/hooks/pre-commit .format-web
.format-web: .biome.json $(web-files)
$(biome) --write $(web-files)
./cache-bust update
$(biome) --write index.html
@touch $@
.PHONY: test
test:
$(biome) $(web-files)
./cache-bust check
.PHONY: fix
fix:
$(biome) --write --unsafe $(web-files)
.git/hooks/pre-commit: pre-commit
cp pre-commit .git/hooks/pre-commit
.PHONY: run
run:
python3 -m http.server --bind 127.0.0.1
.PHONY: clean
clean:
rm -rf format-*
.PHONY: deploy
deploy:
heroku git:remote -a bmo-bugdash
git push heroku main