Cleanup golangci-lint errcheck (#1339)

Move the errcheck excludes list from an external file to inline in the golangci-lint config file.

Signed-off-by: SuperQ <superq@gmail.com>
This commit is contained in:
Ben Kochie 2023-09-03 19:34:37 +02:00 committed by GitHub
parent ca6ba04f2f
commit d03abf3a31
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 5 additions and 6 deletions

View File

@ -53,7 +53,11 @@ linters-settings:
#- pkg: "regexp"
# desc: "Use github.com/grafana/regexp instead of regexp"
errcheck:
exclude: scripts/errcheck_excludes.txt
exclude-functions:
# The following 2 methods always return nil as the error
- (*github.com/cespare/xxhash/v2.Digest).Write
- (*github.com/cespare/xxhash/v2.Digest).WriteString
- (*bufio.Writer).WriteRune
goimports:
local-prefixes: github.com/prometheus/client_golang
gofumpt:

View File

@ -1,5 +0,0 @@
// The following 2 methods always return nil as the error
(*github.com/cespare/xxhash/v2.Digest).Write
(*github.com/cespare/xxhash/v2.Digest).WriteString
(*bufio.Writer).WriteRune