diff --git a/.golangci.yml b/.golangci.yml index 07f7dab..c9313c7 100644 --- a/.golangci.yml +++ b/.golangci.yml @@ -96,36 +96,28 @@ linters: - decorder # checks declaration order and count of types, constants, variables and functions - dogsled # checks assignments with too many blank identifiers (e.g. x, _, _, _, := f()) - paralleltest # detects missing usage of t.Parallel() method in your Go test + - tagalign # checks that struct tags are well aligned - ## you may want to enable + ## may want to enable + # - wrapcheck # checks that errors returned from external packages are wrapped #- gci # controls golang package import order and makes it always deterministic #- ginkgolinter # [if you use ginkgo/gomega] enforces standards of using ginkgo and gomega #- godox # detects FIXME, TODO and other comment keywords #- goheader # checks is file header matches to pattern #- inamedparam # [great idea, but too strict, need to ignore a lot of cases by default] reports interfaces with unnamed method parameters #- interfacebloat # checks the number of methods inside an interface - #- ireturn # accept interfaces, return concrete types - #- tagalign # checks that struct tags are well aligned - #- varnamelen # [great idea, but too many false positives] checks that the length of a variable's name matches its scope - #- wrapcheck # checks that errors returned from external packages are wrapped - #- zerologlint # detects the wrong usage of zerolog that a user forgets to dispatch zerolog.Event + # - ireturn # accept interfaces, return concrete types + # - varnamelen # [great idea, but too many false positives] checks that the length of a variable's name matches its scope # - nlreturn # checks for a new line before return and branch statements to increase code clarity ## disabled # - lll # reports long lines - # - exhaustruct # [highly recommend to enable] checks if all structure fields are initializedgolangci - #- depguard # [replaced by gomodguard] checks if package imports are in a list of acceptable packages - #- dupword # [useless without config] checks for duplicate words in the source code - #- errchkjson # [don't see profit + I'm against of omitting errors like in the first example https://github.com/breml/errchkjson] checks types passed to the json encoding functions. Reports unsupported types and optionally reports occasions, where the check for the returned error can be omitted - #- forcetypeassert # [replaced by errcheck] finds forced type assertions + # - exhaustruct # checks if all structure fields are initialized #- goerr113 # [too strict] checks the errors handling expressions - #- gofmt # [replaced by goimports] checks whether code was gofmt-ed - #- gofumpt # [replaced by goimports, gofumports is not available yet] checks whether code was gofumpt-ed #- gosmopolitan # reports certain i18n/l10n anti-patterns in your Go codebase #- grouper # analyzes expression groups #- importas # enforces consistent import aliases #- maintidx # measures the maintainability index of each function - #- wsl # [too strict and mostly code is not more readable] whitespace linter forces you to use empty lines #- tagliatelle # checks the struct tags #- contextcheck # Check whether the function uses a non-inherited context.