Use Go modules for dependency management (#6912)

This commit is contained in:
Daniel Nelson
2020-01-16 14:38:06 -08:00
committed by GitHub
parent 17c165391b
commit 5f1f4b9e8d
10 changed files with 771 additions and 46 deletions

View File

@@ -32,7 +32,7 @@ all:
.PHONY: deps
deps:
dep ensure -vendor-only
go mod download
.PHONY: telegraf
telegraf:
@@ -83,8 +83,18 @@ vet:
exit 1; \
fi
.PHONY: tidy
tidy:
go mod verify
go mod tidy
@if ! git diff --quiet go.mod go.sum; then \
echo "please run go mod tidy and check in changes"; \
exit 1; \
fi
.PHONY: check
check: fmtcheck vet
@$(MAKE) --no-print-directory tidy
.PHONY: test-all
test-all: fmtcheck vet