-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #205 from hashcloak/add-lint-tools
utils: add lint tools
- Loading branch information
Showing
25 changed files
with
1,665 additions
and
90 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,8 +5,11 @@ default: lint test | |
|
||
.PHONY: lint | ||
lint: | ||
# go get github.com/golangci/golangci-lint/cmd/golangci-lint@v1.44.0 | ||
# cd ../tools && go install github.com/golangci/golangci-lint/cmd/golangci-lint | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout=2m | ||
# cd ../ test && go install honnef.co/go/tools/cmd/[email protected] | ||
# $(GOPATH)/bin/staticcheck ./... | ||
go vet ./... | ||
go fmt ./... | ||
go mod tidy | ||
|
||
|
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 |
---|---|---|
|
@@ -6,8 +6,11 @@ default: lint test | |
# Exclude S1034: assigning the result of this type assertion to a variable (switch cfg := cfg.(type)) could eliminate type assertions in switch cases | ||
.PHONY: lint | ||
lint: | ||
# go get github.com/golangci/golangci-lint/cmd/[email protected] | ||
# $(GOPATH)/bin/golangci-lint run -e gosec -e S1034 ./... --timeout 2m | ||
# cd ../tools && go install github.com/golangci/golangci-lint/cmd/golangci-lint | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout=2m | ||
# cd ../ test && go install honnef.co/go/tools/cmd/[email protected] | ||
# $(GOPATH)/bin/staticcheck ./... | ||
go vet ./... | ||
go fmt ./... | ||
go mod tidy | ||
|
||
|
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 |
---|---|---|
|
@@ -16,8 +16,11 @@ default: lint test | |
|
||
.PHONY: lint | ||
lint: | ||
# go get github.com/golangci/golangci-lint/cmd/[email protected] | ||
# $(GOPATH)/bin/golangci-lint run --timeout 2m0s -e gosec ./... | ||
# cd ../tools && go install github.com/golangci/golangci-lint/cmd/golangci-lint | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout=2m | ||
# cd ../ test && go install honnef.co/go/tools/cmd/[email protected] | ||
# $(GOPATH)/bin/staticcheck ./... | ||
go vet ./... | ||
go fmt ./... | ||
go mod tidy | ||
|
||
|
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 |
---|---|---|
|
@@ -7,8 +7,6 @@ import ( | |
) | ||
|
||
type KatzenmintError struct { | ||
error | ||
|
||
Code uint32 | ||
Msg string | ||
} | ||
|
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 |
---|---|---|
|
@@ -5,8 +5,11 @@ default: lint test | |
|
||
.PHONY: lint | ||
lint: | ||
# go get github.com/golangci/golangci-lint/cmd/[email protected] | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout 2m | ||
# cd ../tools && go install github.com/golangci/golangci-lint/cmd/golangci-lint | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout=2m | ||
# cd ../ test && go install honnef.co/go/tools/cmd/[email protected] | ||
# $(GOPATH)/bin/staticcheck ./... | ||
go vet ./... | ||
go fmt ./... | ||
go mod tidy | ||
|
||
|
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 |
---|---|---|
|
@@ -6,8 +6,11 @@ default: lint test | |
|
||
.PHONY: lint | ||
lint: | ||
# go get github.com/golangci/golangci-lint/cmd/[email protected] | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout 2m | ||
# cd ../tools && go install github.com/golangci/golangci-lint/cmd/golangci-lint | ||
# $(GOPATH)/bin/golangci-lint run -e gosec ./... --timeout=2m | ||
# cd ../ test && go install honnef.co/go/tools/cmd/[email protected] | ||
# $(GOPATH)/bin/staticcheck ./... | ||
go vet ./... | ||
go fmt ./... | ||
go mod tidy | ||
|
||
|
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
Oops, something went wrong.