generated from rizalgowandy/library-template-go
-
-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathMakefile
24 lines (19 loc) · 731 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
.PHONY: help
help: # print all available make commands and their usages.
@printf "\e[32musage: make [target]\n\n\e[0m"
@grep -E '^[a-zA-Z_-]+:.*?# .*$$' $(MAKEFILE_LIST) | sort | awk 'BEGIN {FS = ":.*?# "}; {printf "\033[36m%-30s\033[0m %s\n", $$1, $$2}'
.PHONY: setup
setup: # install configuration and dependencies for development.
@./scripts/setup.sh
.PHONY: linter
linter: # run linter to keep code clean.
@./scripts/linter.sh
.PHONY: test
test: # run all tests.
@./scripts/test.sh
.PHONY: build
build: # ensure all binary can be build. // TODO: replace me
@go build -o bin/library-go && rm bin/library-go
.PHONY: generate
generate: # generate all go generate command inside internal package.
@go generate -v ./...