-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
39 lines (30 loc) · 864 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
.DEFAULT_GOAL := default
.PHONY: ci-run
ci-run: test lint
.PHONY: test
test:
gotestsum ./...
.PHONY: test-no-cache
test-no-cache:
gotestsum ./... -count=1
.PHONY: test-verbose
test-verbose:
gotestsum --format standard-verbose ./...
.PHONY: coverage
coverage:
gotestsum ./... -test.coverprofile coverage.out -test.v
# go test -coverpkg=./... -coverprofile=profile.cov ./... && go tool cover -func profile.cov && rm profile.cov
.PHONY: install-gotestsum
install-gotestsum:
go install gotest.tools/gotestsum@latest
.PHONY: install-linter
install-linter:
go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.42.1
.PHONY: lint
lint:
golangci-lint run
# static check comes with VSCode's Go extension as one of the tools
# will look into adding an install step for it when I get more time
.PHONY: staticcheck
staticcheck:
staticcheck ./...