784 B
784 B
explicitreturn
A Go linter to enforce explicit return values
If you want this linter as a plugin
- Run
make plugin
in the root directory - Put the resulting
explicitreturn.so
wherever you would like to use it - Update your project's
.golangci.yml
file with something like this:
linters-settings:
custom:
explicitreturn:
path: path/to/explicitreturn.so
description: Enforces explicit return statements
original-url: tildegit.org/indigo/explicitreturn
If the plugin gives an error about versions when it should be linting
Odds are you built it with a different version of golangci-lint than your project is using. Make sure the version in go.mod in this project matches the version that your project is using, then do the steps above