Add golangci-lilnt to CI (#1794)

This introduces a linter to PRs to help with code reviews and code hygiene. I've also gone ahead and fixed (or ignored) the existing lints.

I've only setup the default linters right now. There are many more options that are documented at https://golangci-lint.run/.

The GitHub Action should add appropriate annotations to the lint job for the PR. Contributors can also lint locally using `make lint`.
This commit is contained in:
Cory Miller
2022-09-20 20:08:22 -04:00
committed by GitHub
parent 718232f8f4
commit c91e76f169
17 changed files with 63 additions and 87 deletions

View File

@@ -155,3 +155,7 @@ GINKGO_FOCUS='[It] should create a new Runner resource from the specified templa
#### Helm Version Bumps
In general we ask you not to bump the version in your PR, the maintainers in general manage the publishing of a new chart.
#### Running linters locally
To run the `golangci-lint` tool locally, we recommend you use `make lint` to run the tool using a Docker container matching the CI version.