[travis] check module deps
Signed-off-by: Brian Goff <cpuguy83@gmail.com>
Brian Goff
5 years ago
6 | 6 |
- "stable"
|
7 | 7 |
- tip
|
8 | 8 |
|
|
9 |
env:
|
|
10 |
- GO111MODULE: "on"
|
|
11 |
|
9 | 12 |
matrix:
|
10 | 13 |
allow_failures:
|
11 | 14 |
- go: tip
|
12 | 15 |
|
13 | 16 |
script:
|
14 | |
- if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then make golangci-lint
|
|
17 |
- if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then make check-mod; fi
|
|
18 |
- if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then make golangci-lint; fi
|
15 | 19 |
- if [ "${TRAVIS_GO_VERSION}" = "stable" ]; then echo running check scripts; make check; fi
|
16 | 20 |
- make build
|
17 | 21 |
- make TEST_FLAGS="-v" test
|
|
0 |
GO111MODULE ?= on
|
0 | 1 |
LINTER_BIN ?= golangci-lint
|
|
2 |
|
|
3 |
export GO111MODULE
|
1 | 4 |
|
2 | 5 |
.PHONY:
|
3 | 6 |
build: bin/go-md2man
|
|
30 | 33 |
curl -sfL https://install.goreleaser.com/github.com/golangci/golangci-lint.sh | sh -s -- -b $(shell go env GOPATH)/bin v1.15.0; \
|
31 | 34 |
fi
|
32 | 35 |
|
|
36 |
.PHONY: mod
|
|
37 |
mod:
|
|
38 |
@go mod tidy
|
|
39 |
|
|
40 |
.PHONY: check-mod
|
|
41 |
check-mod: # verifies that module changes for go.mod and go.sum are checked in
|
|
42 |
@hack/ci/check_mods.sh
|
|
43 |
|
|
44 |
.PHONY: vendor
|
|
45 |
vendor: mod
|
|
46 |
@go mod vendor -v
|
|
47 |
|