File tree Expand file tree Collapse file tree 2 files changed +10
-11
lines changed Expand file tree Collapse file tree 2 files changed +10
-11
lines changed Original file line number Diff line number Diff line change @@ -52,14 +52,16 @@ linters-settings:
5252 - strings.SplitN
5353
5454 govet :
55- check-shadowing : true
5655 settings :
5756 printf :
5857 funcs :
5958 - (github.com/golangci/golangci-lint/pkg/logutils.Log).Infof
6059 - (github.com/golangci/golangci-lint/pkg/logutils.Log).Warnf
6160 - (github.com/golangci/golangci-lint/pkg/logutils.Log).Errorf
6261 - (github.com/golangci/golangci-lint/pkg/logutils.Log).Fatalf
62+ enable :
63+ - nilness
64+ - shadow
6365 errorlint :
6466 asserts : false
6567 lll :
Original file line number Diff line number Diff line change @@ -236,25 +236,22 @@ func (m Manager) GetAllSupportedLinterConfigs() []*linter.Config {
236236 wrapcheckCfg = & m .cfg .LintersSettings .Wrapcheck
237237 wslCfg = & m .cfg .LintersSettings .WSL
238238
239- if govetCfg != nil {
240- govetCfg .Go = m .cfg .Run .Go
241- }
239+ govetCfg .Go = m .cfg .Run .Go
242240
243- if gocriticCfg != nil {
244- gocriticCfg .Go = trimGoVersion (m .cfg .Run .Go )
245- }
241+ gocriticCfg .Go = trimGoVersion (m .cfg .Run .Go )
246242
247- if gofumptCfg != nil && gofumptCfg .LangVersion == "" {
243+ if gofumptCfg .LangVersion == "" {
248244 gofumptCfg .LangVersion = m .cfg .Run .Go
249245 }
250246
251- if staticcheckCfg != nil && staticcheckCfg .GoVersion == "" {
247+ // staticcheck related linters.
248+ if staticcheckCfg .GoVersion == "" {
252249 staticcheckCfg .GoVersion = trimGoVersion (m .cfg .Run .Go )
253250 }
254- if gosimpleCfg != nil && gosimpleCfg .GoVersion == "" {
251+ if gosimpleCfg .GoVersion == "" {
255252 gosimpleCfg .GoVersion = trimGoVersion (m .cfg .Run .Go )
256253 }
257- if stylecheckCfg != nil && stylecheckCfg .GoVersion != "" {
254+ if stylecheckCfg .GoVersion != "" {
258255 stylecheckCfg .GoVersion = trimGoVersion (m .cfg .Run .Go )
259256 }
260257 }
You can’t perform that action at this time.
0 commit comments