Skip to content

Commit

Permalink
Updated linter
Browse files Browse the repository at this point in the history
  • Loading branch information
mrz1836 committed Aug 5, 2021
1 parent da63fd6 commit c86f474
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 16 deletions.
15 changes: 2 additions & 13 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -197,8 +197,6 @@ linters-settings:
# put imports beginning with prefix after 3rd-party packages;
# it's a comma-separated list of prefixes
local-prefixes: github.com/org/project
golint:
# minimal confidence for issues, default is 0.8
min-confidence: 0.8
gomnd:
settings:
Expand Down Expand Up @@ -239,9 +237,6 @@ linters-settings:
line-length: 120
# tab width in spaces. Default to 1.
tab-width: 1
maligned:
# print struct with more effective memory layout or not, false by default
suggest-new: true
misspell:
# Correct spellings using locale preferences for US or UK.
# Default is to use a neutral variety of English.
Expand Down Expand Up @@ -336,10 +331,9 @@ linters:
- govet
- gosec
- bodyclose
- golint
- revive
- unconvert
- dupl
- maligned
- misspell
- dogsled
- prealloc
Expand Down Expand Up @@ -384,7 +378,6 @@ issues:
- errcheck
- dupl
- gosec
- maligned
- lll

# Exclude known linters from partially hard-vendored code,
Expand All @@ -404,7 +397,7 @@ issues:
- lll
source: "^//go:generate "

# Independently from option `exclude` we use default exclude patterns,
# Independently of option `exclude` we use default exclude patterns,
# it can be disabled by this option. To list all
# excluded by default patterns execute `golangci-lint run --help`.
# Default value for this option is true.
Expand All @@ -414,10 +407,6 @@ issues:
# regular expressions become case sensitive.
exclude-case-sensitive: false

# The list of ids of default excludes to include or disable. By default it's empty.
include:
- EXC0002 # disable excluding of issues about comments from golint

# Maximum issues count per one linter. Set to 0 to disable. Default is 50.
max-issues-per-linter: 0

Expand Down
6 changes: 3 additions & 3 deletions .make/go.mk
Original file line number Diff line number Diff line change
Expand Up @@ -42,11 +42,11 @@ install-go: ## Install the application (Using Native Go)

lint: ## Run the golangci-lint application (install if not found)
@#Travis (has sudo)
@if [ "$(shell command -v golangci-lint)" = "" ] && [ $(TRAVIS) ]; then curl -sSfL https://github.com/raw/golangci/golangci-lint/master/install.sh | sh -s v1.39.0 && sudo cp ./bin/golangci-lint $(go env GOPATH)/bin/; fi;
@if [ "$(shell command -v golangci-lint)" = "" ] && [ $(TRAVIS) ]; then curl -sSfL https://github.com/raw/golangci/golangci-lint/master/install.sh | sh -s v1.41.1 && sudo cp ./bin/golangci-lint $(go env GOPATH)/bin/; fi;
@#AWS CodePipeline
@if [ "$(shell command -v golangci-lint)" = "" ] && [ "$(CODEBUILD_BUILD_ID)" != "" ]; then curl -sSfL https://github.com/raw/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.39.0; fi;
@if [ "$(shell command -v golangci-lint)" = "" ] && [ "$(CODEBUILD_BUILD_ID)" != "" ]; then curl -sSfL https://github.com/raw/golangci/golangci-lint/master/install.sh | sh -s -- -b $(go env GOPATH)/bin v1.41.1; fi;
@#Github Actions
@if [ "$(shell command -v golangci-lint)" = "" ] && [ "$(GITHUB_WORKFLOW)" != "" ]; then curl -sfL https://github.com/raw/golangci/golangci-lint/master/install.sh | sudo sh -s -- -b $(go env GOPATH)/bin v1.39.0; fi;
@if [ "$(shell command -v golangci-lint)" = "" ] && [ "$(GITHUB_WORKFLOW)" != "" ]; then curl -sfL https://github.com/raw/golangci/golangci-lint/master/install.sh | sudo sh -s -- -b $(go env GOPATH)/bin v1.41.1; fi;
@#Brew - MacOS
@if [ "$(shell command -v golangci-lint)" = "" ] && [ "$(shell command -v brew)" != "" ]; then brew install golangci-lint; fi;
@echo "running golangci-lint..."
Expand Down

0 comments on commit c86f474

Please sign in to comment.