-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
41 lines (27 loc) · 996 Bytes
/
Copy pathMakefile
File metadata and controls
41 lines (27 loc) · 996 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
37
38
39
40
41
.PHONY: dev tailwind install-npm install-htmx build-css build-js build-docker build-all run stop restart restart-dev deploy
HTMX_VERSION = 2.0.10
SORTABLEJS_VERSION = 1.15.2
dev:
docker compose up dev db adminer -d
tailwind:
npx tailwindcss -i app/static/css/input.css -o app/static/css/styles.css --watch
install-npm:
npm ci
install-js-pkgs:
curl -o app/static/js/htmx.min.js https://cdn.jsdelivr.net/npm/htmx.org@$(HTMX_VERSION)/dist/htmx.min.js
curl -o app/static/js/Sortable.min.js https://cdn.jsdelivr.net/npm/sortablejs@$(SORTABLEJS_VERSION)/Sortable.min.js
build-css:
npx tailwindcss -m -i app/static/css/input.css -o app/static/css/styles.css
build-js:
npx terser app/static/js/main.js \
-o app/static/js/main.min.js -c -m
build-docker:
docker build -t nihilne/webtools .
build-all: install-npm install-js-pkgs build-css build-js build-docker
run:
docker compose up web db -d
stop:
docker compose down
restart: stop run
restart-dev: stop dev
deploy: build-all run