Skip to content

Commit

Permalink
ci: enable checks for missing Go documentation
Browse files Browse the repository at this point in the history
Checks for missing Go documentation used to be covered by the now
defunct project `golint`. Revive is a replacement for golint that is
used by `golangci-lint`. However, `golangci-lint` disables checks for
missing Go documentation by default[0]. The only way to re-enable them
is apparently to suppress golangci-lint's default rules, which is what
this commit does. Rules that triggered false-positive on this codebase
have been manually added. The list of default exclude rules can be found
by running `golangci-lint run --help`.

[0]: golangci/golangci-lint#456

Signed-off-by: Robin Hahling <robin.hahling@gw-computing.net>
  • Loading branch information
rolinh committed Jun 29, 2021
1 parent 238ea6e commit 385596c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .golangci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,10 @@ linters-settings:
go: "1.16"

issues:
exclude-use-default: false # default rules exclude doc comments check :(
exclude:
- (G104|G307) # EXC0008 gosec: Duplicated errcheck checks

exclude-rules:
- linters: [staticcheck]
text: "SA1019" # deprecated methods
Expand Down

0 comments on commit 385596c

Please sign in to comment.