diff --git a/Makefile b/Makefile index 6dc50ffa3b4509576adccf8fddfd95fa921b72c9..5c7033aeb9829e7d828ac49048d1e9f846f66862 100755 --- a/Makefile +++ b/Makefile @@ -51,7 +51,7 @@ MINIKUBE_RELEASES_URL=https://github.com/kubernetes/minikube/releases/download KERNEL_VERSION ?= 4.15 # latest from https://github.com/golangci/golangci-lint/releases -GOLINT_VERSION ?= v1.17.1 +GOLINT_VERSION ?= v1.18.0 # Limit number of default jobs, to avoid the CI builds running out of memory GOLINT_JOBS ?= 4 # see https://github.com/golangci/golangci-lint#memory-usage-of-golangci-lint @@ -319,14 +319,15 @@ golint: gocyclo: @gocyclo -over 15 `find $(SOURCE_DIRS) -type f -name "*.go"` -out/linters/golangci-lint: +out/linters/golangci-lint-$(GOLINT_VERSION): mkdir -p out/linters curl -sfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b out/linters $(GOLINT_VERSION) + mv out/linters/golangci-lint out/linters/golangci-lint-$(GOLINT_VERSION) # this one is meant for local use .PHONY: lint -lint: pkg/minikube/assets/assets.go pkg/minikube/translate/translations.go out/linters/golangci-lint - ./out/linters/golangci-lint run ${GOLINT_OPTIONS} ./... +lint: pkg/minikube/assets/assets.go pkg/minikube/translate/translations.go out/linters/golangci-lint-$(GOLINT_VERSION) + ./out/linters/golangci-lint-$(GOLINT_VERSION) run ${GOLINT_OPTIONS} ./... # lint-ci is slower version of lint and is meant to be used in ci (travis) to avoid out of memory leaks. .PHONY: lint-ci