gh-ost/vendor/github.com/go-sql-driver/mysql/.travis/gofmt.sh
2019-05-16 13:29:40 +03:00

8 lines
206 B
Bash
Executable File

#!/bin/bash
set -ev
# Only check for go1.10+ since the gofmt style changed
if [[ $(go version) =~ go1\.([0-9]+) ]] && ((${BASH_REMATCH[1]} >= 10)); then
test -z "$(gofmt -d -s . | tee /dev/stderr)"
fi