Its been a busy week since the v1.0.0-beta.1 announcement.
Here's a quick recap of recent additions:
- Support for staticcheck
- Support for invoking custom tools
As an example of invoking custom tools, here's a snippit I gave to a user recently who wanted to invoke
# ... hooks: # Run 'golines -l --dry-run $FILE' for each staged .go file - id: my-cmd name: go-lines alias: go-lines args: [ golines, -l, --dry-run ] # Run 'golines -l --dry-run .' in the repo root folder - id: my-cmd-repo name: go-lines-repo alias: go-lines-preo args: [ golines, -l, --dry-run, . ]
You can read about all pre-commit-golang features on project's homepage: