dnephin / pre-commit-golang

Golang hooks for pre-commit
MIT License
656 stars 222 forks source link

Add staticcheck hook #84

Open kwanhur opened 2 years ago

kwanhur commented 2 years ago

staticcheck hook

dnephin commented 2 years ago

Thank you for the PR! It is possible to run staticcheck as part of the golangci-lint hook. Would that work for your use case, or are you looking to run only staticcheck?

kwanhur commented 2 years ago

Yep, just run only staticcheck.

golangci-lint could do the same, but it has to install both staticcheck and golangci-lint.

Hopefully could separate them.