Skip to content

Commit

Permalink
Merge pull request #2286 from mattnotmitt/chore/fix-pre-commit-hook
Browse files Browse the repository at this point in the history
Pre-commit hook `go vet` correction
  • Loading branch information
docmerlin authored Apr 27, 2020
2 parents 64b5d1d + e346531 commit d33a331
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .hooks/pre-commit
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ if [ $fmtcount -gt 0 ]; then
fi

# Due to the way composites work, vet will fail for some of our tests so we ignore it
vetcount=`go tool vet --composites=false $(go list ./... | grep -v '/vendor/' | sed 's~github.com/influxdata/kapacitor~.~' | grep -v '^\.$') 2>&1 | wc -l`
vetcount=`go vet --composites=false $(go list ./... | grep -v '/vendor/' | sed 's~github.com/influxdata/kapacitor~.~' | grep -v '^\.$') 2>&1 | wc -l`
if [ $vetcount -gt 0 ]; then
echo "Some files aren't passing vet heuristics, please run 'go vet ./...' to see the errors it flags and correct your source code before committing"
exit 1
Expand Down
2 changes: 2 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@

### Bugfixes

- [#2286](https://github.com/influxdata/kapacitor/pull/2286): Corrected issue with `go vet` invocation in .hooks/pre-commit which would cause the hook to fail.

## v1.5.5 [2020-04-20]

### bugfixes
Expand Down

0 comments on commit d33a331

Please sign in to comment.