This repository has been archived by the owner on Aug 23, 2023. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 105
/
Makefile
65 lines (57 loc) · 1.63 KB
/
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
54
55
56
57
58
59
60
61
62
63
64
65
.PHONY: test bin docker debug stacktest
default:
$(MAKE) all
test:
GO111MODULE=off CGO_ENABLED=1 go test -race -short ./...
test-all:
GO111MODULE=off CGO_ENABLED=1 go test -race ./...
benchmark:
GO111MODULE=off CGO_ENABLED=0 go test -count=10 -run='^$$' -bench=. -benchtime=100ms ./... | tee benchmark.txt
stacktest:
# count=1 forces uncached runs
# not using stacktest/... here because Go would run them all in parallel,
# or at least the TestMain's, and the stacks would conflict with each other
GO111MODULE=off go test -count=1 -v ./stacktest/tests/chaos_cluster
GO111MODULE=off go test -count=1 -v ./stacktest/tests/end2end_carbon
GO111MODULE=off go test -count=1 -v ./stacktest/tests/end2end_carbon_bigtable
check:
$(MAKE) test
bin:
./scripts/build.sh
bin-race:
./scripts/build.sh -race
docker:
./scripts/build_docker.sh
qa: bin qa-common
#refresh content in docs/tools.md, strictly a dev time task that is exluded from the `all` target
document-tools:
./scripts/dev/tools-to-doc.sh > docs/tools.md
#debug versions for remote debugging with delve
bin-debug:
./scripts/build.sh -debug
docker-debug:
./scripts/build_docker.sh -debug
qa-debug: bin-debug qa-common
qa-common:
# regular qa steps (can run directly on code)
scripts/qa/gofmt.sh
scripts/qa/go-generate.sh
scripts/qa/ineffassign.sh
scripts/qa/misspell.sh
scripts/qa/gitignore.sh
scripts/qa/unused.sh
scripts/qa/vendor.sh
scripts/qa/vet-high-confidence.sh
# qa-post-build steps minus stack tests
scripts/qa/docs.sh
all:
$(MAKE) bin
$(MAKE) docker
$(MAKE) qa
debug:
$(MAKE) bin-debug
$(MAKE) docker-debug
$(MAKE) qa-debug
clean:
rm build/*
rm scripts/build/*