File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed
Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -79,8 +79,15 @@ test: manifests generate fmt vet envtest ## Run tests.
7979 go tool cover --html=cover.out -o cover.html
8080 go tool cover -func cover.out | tail -n 1
8181
82+ .PHONY : golangci-lint
83+ golangci-lint : localbin # # Download golangci-lint locally if necessary. If wrong version is installed, it will be overwritten.
84+ @test -s $(LINTER ) && $(LINTER ) --version | grep -q $(subst v,,$(LINTER_VERSION ) ) || \
85+ ( echo " Installing golangci-lint $( LINTER_VERSION) ..." ; \
86+ curl -sSfL https://raw.githubusercontent.com/golangci/golangci-lint/master/install.sh | sh -s -- -b $(LOCALBIN ) $(LINTER_VERSION ) )
87+
88+
8289.PHONY : lint
83- lint : # # Run golangci-lint to lint code
90+ lint :golangci-lint # # Run golangci-lint to lint code
8491 golangci-lint run ./... --timeout=15m
8592
8693.PHONY : tidy
You can’t perform that action at this time.
0 commit comments