ccchatbot/.ci/check-gofmt
2019-08-06 20:31:58 +02:00

8 lines
175 B
Bash
Executable file

#!/bin/bash
result="$(gofmt -s -l . | grep -v '^vendor/' )"
if [ -n "$result" ]; then
echo "Go code is not formatted, run 'gofmt -s -w .'" >&2
echo "$result"
exit 1
fi