我在工作目录中创建了一个,其中有多个默认值,并运行但发现linter仍然是默认值,有人遇到同样的问题吗?我已经检查了路径是否正确。以下是我们的配置值:.golangci.ymllintersgolangci-lint run -v.golangci.ymllinters:disable-all: trueenable: - bodyclose - deadcode - depguard - dogsled - dupl - errcheck - exhaustive - gochecknoinits - goconst - gocritic - gofmt - gomnd - goprintffuncname - gosec - gosimple - govet - ineffassign - interfacer - lll - misspell - nakedret - noctx
1 回答

呼如林
TA贡献1798条经验 获得超3个赞
此 yaml 文件未正确缩进。尝试:
linters:
enable:
- bodyclose
- deadcode
- depguard
- dogsled
- dupl
- errcheck
- exhaustive
- gochecknoinits
- goconst
- gocritic
- gofmt
- gomnd
- goprintffuncname
- gosec
- gosimple
- govet
- ineffassign
- interfacer
- lll
- misspell
- nakedret
- noctx
- 1 回答
- 0 关注
- 61 浏览
添加回答
举报
0/150
提交
取消