-
-
Notifications
You must be signed in to change notification settings - Fork 42
/
Makefile
43 lines (38 loc) · 828 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
39
40
41
42
43
# Run the main server
run:
go run -race cmd/server/main.go -c config.local
.PHONY: run
# Run tests
test:
go test -race ./internal/...
.PHONY: test
# Run vet
vet:
go vet ./internal/...
.PHONY: vet
# Run docker compose
docker:
docker-compose -f docker-compose.yml -f docker-compose.dev.yml up -d --build
.PHONY: docker
# Watch frontend files to run esbuild on any change
watch:
esbuild ./web/css/style.css \
--bundle \
--outdir=./web/static \
--public-path=/resources \
--loader:.woff=file \
--loader:.woff2=file \
--loader:.png=file \
--watch
.PHONY: watch
# Run esbuild to compile the frontend files
front:
esbuild ./web/css/style.css \
--bundle \
--minify \
--outdir=./web/static \
--public-path=/resources \
--loader:.woff=file \
--loader:.woff2=file \
--loader:.png=file
.PHONY: front