Some checks failed
CI / Lint (push) Successful in 54s
CI / Build & Test (ubuntu-latest) (push) Successful in 27s
CI / Build & Test (macos-latest) (push) Has been cancelled
CI / Build & Test (windows-latest) (push) Has been cancelled
CI / Build Roslyn Helper (push) Has been cancelled
Baixa versão Go de 1.26 para 1.24 em go.mod, .golangci.yml e CI. golangci-lint v1.64.8 compilado com Go 1.24 — não suportava 1.26. Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
70 lines
1.9 KiB
YAML
70 lines
1.9 KiB
YAML
run:
|
|
timeout: 3m
|
|
tests: true
|
|
go: "1.24"
|
|
|
|
output:
|
|
formats:
|
|
- format: colored-line-number
|
|
print-issued-lines: true
|
|
print-linter-name: true
|
|
sort-results: true
|
|
|
|
linters:
|
|
disable-all: true
|
|
enable:
|
|
- errcheck # unhandled errors
|
|
- govet # official compiler checks
|
|
- ineffassign # useless assignments
|
|
- staticcheck # bugs and simplifications
|
|
- unused # dead code
|
|
- gofmt # formatting
|
|
- goimports # import organization
|
|
- misspell # typos in strings/comments
|
|
- revive # golint successor
|
|
- gocyclo # high cyclomatic complexity
|
|
- gocritic # additional checks
|
|
- bodyclose # http.Response.Body closed
|
|
- nilerr # returning nil when err intended
|
|
- errorlint # non-wrappable errors
|
|
|
|
linters-settings:
|
|
gocyclo:
|
|
min-complexity: 15
|
|
govet:
|
|
enable-all: true
|
|
disable:
|
|
- fieldalignment # unnecessary noise
|
|
revive:
|
|
rules:
|
|
- name: var-naming
|
|
- name: exported
|
|
arguments: ["disableStutteringCheck"] # allows ctx.Context
|
|
- name: error-return
|
|
- name: error-naming
|
|
- name: unexported-return
|
|
- name: indent-error-flow
|
|
- name: unreachable-code
|
|
|
|
issues:
|
|
exclude-dirs:
|
|
- tools/roslyn-helper # C# code, ignore
|
|
- vendor
|
|
- bin
|
|
exclude-rules:
|
|
# Allow errcheck in cobra command handlers — cobra's RunE owns error printing
|
|
- path: cmd/
|
|
linters: [errcheck]
|
|
# Allow higher complexity in plugin format functions (inherently procedural)
|
|
- path: internal/plugins/.*/format\.go
|
|
linters: [gocyclo]
|
|
text: "cyclomatic complexity"
|
|
# Allow higher complexity in plugin collect/detect logic
|
|
- path: internal/plugins/.*/detect
|
|
linters: [gocyclo]
|
|
text: "cyclomatic complexity"
|
|
|
|
max-issues-per-linter: 0
|
|
max-same-issues: 0
|
|
new: false
|