-
Notifications
You must be signed in to change notification settings - Fork 557
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Swaps lint tooling from golint to golangci-lint. Resolve lint warnings for deprecated package io/ioutil. Adds Go strategy matrix for Go 1.18, 1.19, and 1.20. Update actions/setup-go package from v1 to v3 to resolve CI warnings. Signed-off-by: Austin Vazquez <[email protected]>
- Loading branch information
1 parent
7301c34
commit 2434407
Showing
4 changed files
with
29 additions
and
29 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -61,12 +61,9 @@ test: .govet .golint .gitvalidation | |
.govet: | ||
go vet -x ./... | ||
|
||
# `go get github.com/golang/lint/golint` | ||
.golint: | ||
ifeq ($(call ALLOWED_GO_VERSION,1.7,$(HOST_GOLANG_VERSION)),true) | ||
@which golint > /dev/null 2>/dev/null || (echo "ERROR: golint not found. Consider 'make install.tools' target" && false) | ||
golint ./... | ||
endif | ||
.lint: | ||
@which golangci-lint > /dev/null 2>/dev/null || (echo "ERROR: golangci-lint not found. Consider 'make install.tools' target" && false) | ||
golangci-lint run | ||
|
||
|
||
# When this is running in GitHub, it will only check the GitHub commit range | ||
|
@@ -78,16 +75,13 @@ else | |
git-validation -v -run DCO,short-subject,dangling-whitespace -range $(EPOCH_TEST_COMMIT)..HEAD | ||
endif | ||
|
||
install.tools: .install.golint .install.gitvalidation | ||
install.tools: .install.lint .install.gitvalidation | ||
|
||
# golint does not even build for <go1.7 | ||
.install.golint: | ||
ifeq ($(call ALLOWED_GO_VERSION,1.7,$(HOST_GOLANG_VERSION)),true) | ||
go get -u golang.org/x/lint/golint | ||
endif | ||
.install.lint: | ||
go install github.com/golangci/golangci-lint/cmd/[email protected] | ||
|
||
.install.gitvalidation: | ||
go get -u github.com/vbatts/git-validation | ||
go install github.com/vbatts/git-validation@v1.1.0 | ||
|
||
clean: | ||
rm -rf $(OUTPUT_DIRNAME) *~ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters