chore(deps): update golangci-lint to 1.43

This commit is contained in:
2021-12-17 00:10:50 +00:00
parent b59d421322
commit 0a42d1e112
3 changed files with 25 additions and 8 deletions

View File

@@ -11,7 +11,7 @@ jobs:
- name: golangci-lint - name: golangci-lint
uses: golangci/golangci-lint-action@v2 uses: golangci/golangci-lint-action@v2
with: with:
version: v1.35 version: v1.43
env: env:
VERBOSE: "true" VERBOSE: "true"

View File

@@ -9,6 +9,8 @@ linters-settings:
govet: govet:
check-shadowing: true check-shadowing: true
enable-all: true enable-all: true
disable:
- fieldalignment
lll: lll:
line-length: 80 line-length: 80
tab-width: 4 tab-width: 4
@@ -20,43 +22,52 @@ linters-settings:
linters: linters:
disable-all: true disable-all: true
enable: enable:
- asciicheck
- bodyclose - bodyclose
- deadcode - deadcode
- depguard - depguard
- dupl - durationcheck
- errcheck - errcheck
- errorlint
- exhaustive
- exportloopref
- funlen - funlen
- gochecknoinits - gochecknoinits
- goconst - goconst
- gocritic - gocritic
- gocyclo - gocyclo
- goerr113 - godot
- gofumpt
- goimports - goimports
- golint
- goprintffuncname - goprintffuncname
- gosec - gosec
- gosimple - gosimple
- govet - govet
- importas
- ineffassign - ineffassign
- lll - lll
- misspell - misspell
- nakedret - nakedret
- nilerr
- nlreturn - nlreturn
- noctx - noctx
- nolintlint - nolintlint
- scopelint - prealloc
- predeclared
- revive
- rowserrcheck
- sqlclosecheck - sqlclosecheck
- staticcheck - staticcheck
- structcheck - structcheck
- typecheck - typecheck
- unconvert - unconvert
- unparam
- unused - unused
- varcheck - varcheck
- wastedassign
- whitespace - whitespace
issues: issues:
include:
# - EXC0002 # disable excluding of issues about comments from golint
exclude: exclude:
- Using the variable on range scope `tt` in function literal - Using the variable on range scope `tt` in function literal
- Using the variable on range scope `tc` in function literal - Using the variable on range scope `tc` in function literal
@@ -71,6 +82,12 @@ issues:
- source: "`json:" - source: "`json:"
linters: linters:
- lll - lll
- source: "`xml:"
linters:
- lll
- source: "`yaml:"
linters:
- lll
run: run:
timeout: 2m timeout: 2m

View File

@@ -52,7 +52,7 @@ endef
$(eval $(call tool,godoc,golang.org/x/tools/cmd/godoc)) $(eval $(call tool,godoc,golang.org/x/tools/cmd/godoc))
$(eval $(call tool,gofumports,mvdan.cc/gofumpt/gofumports)) $(eval $(call tool,gofumports,mvdan.cc/gofumpt/gofumports))
$(eval $(call tool,golangci-lint,github.com/golangci/golangci-lint/cmd/golangci-lint@v1.35)) $(eval $(call tool,golangci-lint,github.com/golangci/golangci-lint/cmd/golangci-lint@v1.43))
$(eval $(call tool,gomod,github.com/Helcaraxan/gomod)) $(eval $(call tool,gomod,github.com/Helcaraxan/gomod))
.PHONY: tools .PHONY: tools