v/script/format.sh

8 lines
113 B
Bash
Raw Normal View History

#!/usr/bin/bash
if [[ -z "$FIX" ]]; then
[ -z "$(gofmt -s -l ./)" ] || exit 1
else
gofmt -s -l -w ./
fi