pre-commit-golang icon indicating copy to clipboard operation
pre-commit-golang copied to clipboard

Using simpler oneliner for go vet

Open arschles opened this issue 4 years ago • 1 comments

The go vet check is failing in this PR (the logs are here). I'm not sure what's going on, but modern go vet ./... will run through all files in the repo. this is suboptimal, but it's not extremely slow in many cases. perhaps there should be two checks? just an idea, not sure if it's necessary

arschles avatar Oct 26 '20 21:10 arschles

There have been a number of PRs opened to fix/improve the govet hook. My latest recommendation is here.

If you want to run go vet on all files, I think that can already be done using the golangci-lint hook. You can configure golangci-lint to run go vet, and it always runs on all files. From the output you linked it seems like this is already being done. So maybe you can remove the govet hook entirely from your config?

dnephin avatar Oct 27 '20 00:10 dnephin