mirror of
https://github.com/FloatTech/ZeroBot-Plugin.git
synced 2025-12-18 20:50:12 +08:00
76 lines
1.7 KiB
YAML
76 lines
1.7 KiB
YAML
linters-settings:
|
|
errcheck:
|
|
ignoretests: true
|
|
|
|
goimports:
|
|
local-prefixes: github.com/FloatTech/ZeroBot-Plugin
|
|
|
|
forbidigo:
|
|
# Forbid the following identifiers
|
|
forbid:
|
|
- ^fmt\.Errorf$ # consider errors.Errorf in github.com/pkg/errors
|
|
|
|
linters:
|
|
# please, do not use `enable-all`: it's deprecated and will be removed soon.
|
|
# inverted configuration with `enable-all` and `disable` is not scalable during updates of golangci-lint
|
|
disable-all: true
|
|
fast: false
|
|
enable:
|
|
- bodyclose
|
|
#- depguard
|
|
- dogsled
|
|
- errcheck
|
|
#- exportloopref
|
|
- exhaustive
|
|
#- funlen
|
|
#- goconst
|
|
- gocritic
|
|
#- gocyclo
|
|
- gofmt
|
|
- goimports
|
|
- goprintffuncname
|
|
#- gosec
|
|
- gosimple
|
|
- govet
|
|
- ineffassign
|
|
#- misspell
|
|
- nolintlint
|
|
- rowserrcheck
|
|
- staticcheck
|
|
- stylecheck
|
|
- typecheck
|
|
- unconvert
|
|
- unparam
|
|
- unused
|
|
- whitespace
|
|
- prealloc
|
|
- predeclared
|
|
- asciicheck
|
|
- revive
|
|
- forbidigo
|
|
- makezero
|
|
|
|
run:
|
|
# default concurrency is a available CPU number.
|
|
# concurrency: 4 # explicitly omit this value to fully utilize available resources.
|
|
deadline: 5m
|
|
issues-exit-code: 1
|
|
tests: false
|
|
go: '1.25'
|
|
|
|
# output configuration options
|
|
output:
|
|
formats:
|
|
- format: "colored-line-number"
|
|
print-issued-lines: true
|
|
print-linter-name: true
|
|
|
|
issues:
|
|
# Fix found issues (if it's supported by the linter)
|
|
fix: true
|
|
exclude-use-default: false
|
|
uniq-by-line: true
|
|
exclude:
|
|
- "Error return value of .((os.)?std(out|err)..*|.*Close|.*Seek|.*Flush|os.Remove(All)?|.*print(f|ln)?|os.(Un)?Setenv). is not check"
|
|
- 'identifier ".*" contain non-ASCII character: U\+.*'
|