1
1
mirror of https://github.com/OpenDiablo2/OpenDiablo2 synced 2024-06-12 10:40:42 +00:00

Update golangci

* Replace 'maligned' with 'fieldalignment' [1]
* Remove 'interfacer' [2]
* Enable linting against go test files as well
* Disable 'funlen' linter for go table-driven tests

[1] https://github.com/golangci/golangci-lint/pull/1765
[2] https://github.com/golangci/golangci-lint/issues/541
This commit is contained in:
Panagiotis Georgiadis 2021-03-24 15:00:54 +01:00
parent 236a091997
commit 841a3a34bc
No known key found for this signature in database
GPG Key ID: A5B9AF563B15B24F

View File

@ -57,9 +57,8 @@ linters:
- gosimple - gosimple
- govet - govet
- ineffassign - ineffassign
- interfacer
- lll - lll
- maligned - fieldalignment
- misspell - misspell
- nakedret - nakedret
- prealloc - prealloc
@ -78,11 +77,18 @@ linters:
run: run:
timeout: 5m timeout: 5m
tests: true
skip-dirs: skip-dirs:
- .github - .github
- build - build
- web - web
issues: issues:
exclude-rules:
- linters:
- funlen
# Disable 'funlen' linter for test functions.
# It's common for table-driven tests to be more than 60 characters long
source: "^func Test"
max-same-issues: 0 max-same-issues: 0
exclude-use-default: false exclude-use-default: false