Skip to content

Commit

Permalink
Actually fail if (go vet) fails
Browse files Browse the repository at this point in the history
The errors are printed on stderr, so read that.

Signed-off-by: Miloslav Trmač <[email protected]>
  • Loading branch information
mtrmac committed Apr 6, 2023
1 parent aebab49 commit f8f5a25
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion hack/validate-vet.sh
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#!/bin/bash

errors=$(go vet -tags="${BUILDTAGS}" ./...)
errors=$(go vet -tags="${BUILDTAGS}" ./... 2>&1)

if [ -z "$errors" ]; then
echo 'Congratulations! All Go source files have been vetted.'
Expand Down

0 comments on commit f8f5a25

Please sign in to comment.