You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
7 lines
181 B
Bash
7 lines
181 B
Bash
9 years ago
|
#!/bin/bash
|
||
|
fmtcount=`git ls-files | grep '.go$' | xargs gofmt -l 2>&1 | wc -l`
|
||
|
if [ $fmtcount -gt 0 ]; then
|
||
|
echo "run 'go fmt ./...' to format your source code."
|
||
|
exit 1
|
||
|
fi
|