build: Fix Travis vet issues (#14010)
* Use latest in go 1.8 branch for travis * Fix ongoing vet issues Move vet step after the testing step in travis Correct Makefile vet step to check correct files
This commit is contained in:
parent
8eb3ac2b71
commit
3f7a117148
|
@ -2,7 +2,7 @@ dist: trusty
|
|||
sudo: false
|
||||
language: go
|
||||
go:
|
||||
- 1.8
|
||||
- 1.8.x
|
||||
|
||||
# add TF_CONSUL_TEST=1 to run consul tests
|
||||
# they were causing timouts in travis
|
||||
|
@ -25,7 +25,7 @@ install:
|
|||
- bash scripts/gogetcookie.sh
|
||||
- go get github.com/kardianos/govendor
|
||||
script:
|
||||
- make vet vendor-status test
|
||||
- make vendor-status test vet
|
||||
- GOOS=windows go build
|
||||
branches:
|
||||
only:
|
||||
|
|
4
Makefile
4
Makefile
|
@ -75,8 +75,8 @@ cover:
|
|||
# vet runs the Go source code static analysis tool `vet` to find
|
||||
# any common errors.
|
||||
vet:
|
||||
@echo "go vet ."
|
||||
@go vet $$(go list ./... | grep -v vendor/) ; if [ $$? -eq 1 ]; then \
|
||||
@echo 'go vet $$(go list ./... | grep -v /terraform/vendor/)'
|
||||
@go vet $$(go list ./... | grep -v /terraform/vendor/) ; if [ $$? -eq 1 ]; then \
|
||||
echo ""; \
|
||||
echo "Vet found suspicious constructs. Please check the reported constructs"; \
|
||||
echo "and fix them if necessary before submitting the code for review."; \
|
||||
|
|
Loading…
Reference in New Issue