-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
53 lines (36 loc) · 834 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
44
45
46
47
48
49
50
51
52
53
.PHONY: info fmt goimports gofumpt lint go_fix go_vet golangci test coverage build install clean
BINARY = fmtquotecheck
$(BINARY):
go build -o $(BINARY) ./cmd/fmtquotecheck
info:
go version
fmt: goimports gofumpt
$(info === format done)
goimports:
goimports -e -l -w -local github.com/peczenyj/fmtquotecheck .
gofumpt:
gofumpt -l -w -extra .
lint: go.sum go_fix go_vet golangci
$(info === lint done)
go.mod:
go mod tidy
go mod verify
go.sum: go.mod
go_fix:
go fix ./...
go_vet:
go vet -all ./...
golangci:
golangci-lint run ./...
test:
go test -v ./...
coverage:
export GOEXPERIMENT="nocoverageredesign"
go test -v -race -cover -covermode=atomic -coverprofile coverage.out ./...
build: $(BINARY)
install:
go install ./cmd/fmtquotecheck
clean:
rm -f $(BINARY)
rm -f coverage.*
rm -f .test_report.xml