forked from bookstairs/bookhunter
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
22 lines (17 loc) · 632 Bytes
/
Makefile
File metadata and controls
22 lines (17 loc) · 632 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
.PHONY: help build test deps clean
help: ## Display this help
@awk 'BEGIN {FS = ":.*##"; printf "\nUsage:\n make \033[36m<target>\033[0m\n\nTargets:\n"} \
/^[a-zA-Z_-]+:.*?##/ { printf " \033[36m%-10s\033[0m %s\n", $$1, $$2 }' $(MAKEFILE_LIST)
build: ## Build executable files
@goreleaser release --clean --snapshot
test: ## Run tests
go install "github.com/rakyll/gotest@latest"
GIN_MODE=release
LOG_LEVEL=fatal ## disable log for test
gotest -v -coverprofile=coverage.out -covermode=atomic ./...
deps: ## Update vendor.
go mod verify
go mod tidy -v
go get -u ./...
clean: ## Clean up build files.
rm -rf dist/