-
Notifications
You must be signed in to change notification settings - Fork 6
Expand file tree
/
Copy pathMakefile
More file actions
38 lines (30 loc) · 1.04 KB
/
Makefile
File metadata and controls
38 lines (30 loc) · 1.04 KB
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
.PHONY: clean
clean: ## Removes builds and compiled templates
@rm -rf tmp/*.hashcode
@rm -rf out
@find ./views -type f -name '*.html.go' -exec rm {} +
.PHONY: dev
dev: ## Start the project, reloading on changes
@bin/dev.sh
.PHONY: templates
templates:
@bin/templates.sh
.PHONY: build
build: export GOEXPERIMENT=jsonv2
build: templates ## Build all binaries
@go build -gcflags "all=-N -l" -o build/debug/projectforge .
.PHONY: build-verbose
build-verbose: export GOEXPERIMENT=jsonv2
build-verbose: templates ## Build all binaries
@go build -v -x -gcflags "all=-N -l" -o build/debug/projectforge .
.PHONY: build-release
build-release: export GOEXPERIMENT=jsonv2
build-release: templates ## Build all binaries without debug information, clean up after
@go build -ldflags '-s -w' -trimpath -o build/release/projectforge .
.PHONY: lint
lint: ## Run linter
@bin/check.sh
.PHONY: help
help:
@grep -E '^[a-zA-Z_-]+:.*?## .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?## "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
.DEFAULT_GOAL := help