-
Notifications
You must be signed in to change notification settings - Fork 11
/
Makefile
30 lines (24 loc) · 615 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
.PHONY: init
init:
go build -modfile=tools/go.mod -o bin/gofumpt mvdan.cc/gofumpt
go build -modfile=tools/go.mod -o bin/golangci-lint github.com/golangci/golangci-lint/cmd/golangci-lint
.PHONY: check
check:
bin/golangci-lint run
FILES = $(shell find . -type f -name '*.go' -not -path "./vendor/*")
.PHONY: format
format:
go mod tidy
bin/gofumpt -w $(FILES)
.PHONY: test
test:
go test -v ./... -cover
.PHONY: integration
integration:
go test -v . -cover -coverprofile=coverage.out -tags=integration
go tool cover -html=coverage.out -o coverage.html
.PHONY: all
all:
make check
make format
make test