Description
We're starting to adopt golangci-lint at my workplace and it's been really great to use so far, thanks for making this useful tool. We're currently standardizing on pre-commit (https://pre-commit.com/) as our main entrypoint to run linters, since we need to support other languages like Python and having a single tool provides a unified experience for all developers. It also has a config file that lets us define the version of each linter to run in a structured format amenable to automated updates, unlike our current approach of ad-hoc lines in Dockerfiles or shell scripts, and ensures developers automatically have the correct version locally as well.
In order to run golangci-lint from pre-commit, there needs to be a .pre-commit-hooks.yaml
file in the golangci-lint repo. Would it be possible to add one to this repo? I did some testing with a local checkout and it appears that the relevant settings from https://pre-commit.com/#pre-commit-configyaml---hooks would be id
, name
, description
, entry
, language
, types
, and pass_filenames
(that one should be false I think).
I would have made a PR myself, but am still going through the legal review process at my workspace to have golangci-lint approved as an upstream (per #267), so I thought I would ask if one of the maintainers could add this file in the meantime. I am happy to review any PRs to do so.
Please include the following information:
- Version of golangci-lint:
golangci-lint --version
(or git commit if you don't use binary distribution)
golangci-lint has version 1.11.2 built from f5f7701 on 2018-10-29T14:14:06Z