Skip to content

Commit a0f08c8

Browse files
committed
Add golint to lint target
1 parent 61b6aa5 commit a0f08c8

File tree

1 file changed

+5
-2
lines changed

1 file changed

+5
-2
lines changed

Makefile

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -109,9 +109,10 @@ vet: ## Run go vet on the whole project.
109109
go vet ./...
110110

111111
.PHONY: lint
112-
lint: bin/golangci-lint ## Run linting for the project.
112+
lint: bin/golangci-lint bin/golint generate-mocks ## Run linting for the project.
113113
go fmt ./...
114114
go vet ./...
115+
golint api/... controllers/... pkg/...
115116
golangci-lint run -v --timeout 360s ./...
116117
@ # The below string of commands checks that ginkgo isn't present in the controllers.
117118
@(grep ginkgo ${PROJECT_DIR}/controllers/cloudstack*_controller.go && \
@@ -132,11 +133,13 @@ undeploy: bin/kustomize ## Undeploy controller from the K8s cluster specified in
132133
##@ Binaries
133134

134135
.PHONY: binaries
135-
binaries: bin/controller-gen bin/kustomize bin/ginkgo bin/golangci-lint bin/mockgen bin/kubectl ## Locally install all needed bins.
136+
binaries: bin/controller-gen bin/kustomize bin/ginkgo bin/golangci-lint bin/golint bin/mockgen bin/kubectl ## Locally install all needed bins.
136137
bin/controller-gen: ## Install controller-gen to bin.
137138
GOBIN=$(PROJECT_DIR)/bin go install sigs.k8s.io/controller-tools/cmd/[email protected]
138139
bin/golangci-lint: ## Install golangci-lint to bin.
139140
GOBIN=$(PROJECT_DIR)/bin go install github.com/golangci/golangci-lint/cmd/[email protected]
141+
bin/golint: ## Install golint to bin.
142+
GOBIN=$(PROJECT_DIR)/bin go install golang.org/x/lint/golint
140143
bin/ginkgo: ## Install ginkgo to bin.
141144
GOBIN=$(PROJECT_DIR)/bin go install github.com/onsi/ginkgo/[email protected]
142145
bin/mockgen:

0 commit comments

Comments
 (0)