2019-07-11 18:44:12 +08:00
|
|
|
---
|
|
|
|
run:
|
|
|
|
concurrency: 6
|
|
|
|
deadline: 5m
|
2020-01-13 19:00:08 +08:00
|
|
|
skip-dirs-use-default: true
|
2019-07-11 18:44:12 +08:00
|
|
|
skip-dirs:
|
|
|
|
- contrib
|
2020-01-14 03:06:42 +08:00
|
|
|
- dependencies
|
2019-07-11 18:44:12 +08:00
|
|
|
skip-files:
|
2020-01-14 03:13:00 +08:00
|
|
|
- swagger.go
|
2020-06-26 05:38:33 +08:00
|
|
|
modules-download-mode: readonly
|
2019-07-11 18:44:12 +08:00
|
|
|
linters:
|
2020-01-13 19:03:57 +08:00
|
|
|
enable-all: true
|
|
|
|
disable:
|
2023-06-19 20:04:01 +08:00
|
|
|
# too many reports but requires attention
|
|
|
|
- depguard
|
|
|
|
- tagalign
|
2024-02-13 05:47:09 +08:00
|
|
|
- perfsprint
|
|
|
|
- typecheck
|
2023-06-19 20:04:01 +08:00
|
|
|
# useful hints that should be addressed
|
2023-10-20 22:23:33 +08:00
|
|
|
- testifylint # all of reports that should be fixed
|
2023-06-19 20:04:01 +08:00
|
|
|
- nakedret
|
|
|
|
- gosmopolitan # usage of time.Local in pkg/k8s.io
|
2022-03-21 21:14:59 +08:00
|
|
|
- tagliatelle # too many JSON keys cannot be changed due to compat
|
2022-09-30 20:25:31 +08:00
|
|
|
- nosnakecase # too many false positives due to the `unix` package
|
2022-12-15 20:39:56 +08:00
|
|
|
- dupword # too many false positives (e.g., in tests)
|
2021-02-10 02:23:32 +08:00
|
|
|
- gocognit
|
|
|
|
- testpackage
|
|
|
|
- goerr113
|
|
|
|
- exhaustivestruct
|
|
|
|
- errorlint
|
|
|
|
- wrapcheck
|
|
|
|
- paralleltest
|
|
|
|
- wsl
|
|
|
|
- godox
|
|
|
|
- tparallel
|
|
|
|
- gomnd
|
|
|
|
- nlreturn
|
|
|
|
- noctx
|
|
|
|
- nestif
|
|
|
|
- predeclared
|
|
|
|
- thelper
|
|
|
|
- ifshort
|
|
|
|
- forbidigo
|
|
|
|
- exhaustive
|
|
|
|
- gofumpt
|
|
|
|
- gci
|
|
|
|
- godot
|
2020-01-13 19:03:57 +08:00
|
|
|
- dupl
|
|
|
|
- funlen
|
|
|
|
- gochecknoglobals
|
|
|
|
- gochecknoinits
|
|
|
|
- goconst
|
|
|
|
- gocyclo
|
|
|
|
- lll
|
2020-06-26 05:38:33 +08:00
|
|
|
- gosec
|
2020-01-13 19:03:57 +08:00
|
|
|
- maligned
|
2023-02-07 20:54:46 +08:00
|
|
|
- musttag # way to many warnings to fix for now, also some false positives
|
2022-03-21 17:28:35 +08:00
|
|
|
- gomoddirectives
|
|
|
|
- containedctx
|
|
|
|
- contextcheck
|
|
|
|
- cyclop
|
|
|
|
- errname
|
|
|
|
- forcetypeassert
|
|
|
|
- ireturn
|
|
|
|
- varnamelen
|
|
|
|
- maintidx
|
|
|
|
- nilnil
|
2022-06-16 01:50:39 +08:00
|
|
|
- nonamedreturns
|
|
|
|
- exhaustruct
|
2022-04-22 19:38:41 +08:00
|
|
|
# deprecated linters
|
|
|
|
- golint # replaced by revive
|
|
|
|
- scopelint # replaced by exportloopref
|
|
|
|
- interfacer
|
2022-12-06 03:51:51 +08:00
|
|
|
- deadcode # deprecated since v1.49.0, replaced by unused
|
|
|
|
- structcheck # deprecated since v1.49.0, replaced by unused
|
|
|
|
- varcheck # deprecated since v1.49.0, replaced by unused
|
2020-04-03 06:58:23 +08:00
|
|
|
linters-settings:
|
|
|
|
errcheck:
|
|
|
|
check-blank: false
|
2022-04-27 20:28:38 +08:00
|
|
|
ignore: fmt:.*
|
2022-06-13 22:08:46 +08:00
|
|
|
nolintlint:
|
|
|
|
allow-leading-space: false
|
2023-06-19 21:20:57 +08:00
|
|
|
allow-unused: true
|
2022-06-13 22:08:46 +08:00
|
|
|
require-specific: true
|
2023-06-19 21:20:57 +08:00
|
|
|
revive:
|
|
|
|
rules:
|
|
|
|
- name: unused-parameter
|
|
|
|
disabled: true
|
2023-02-07 21:17:30 +08:00
|
|
|
|
|
|
|
issues:
|
|
|
|
# Maximum issues count per one linter.
|
|
|
|
# Set to 0 to disable.
|
|
|
|
# Default: 50
|
|
|
|
max-issues-per-linter: 0
|
|
|
|
# Maximum count of issues with the same text.
|
|
|
|
# Set to 0 to disable.
|
|
|
|
# Default: 3
|
|
|
|
max-same-issues: 0
|