diff --git a/would-reformat.sh b/would-reformat.sh index 627f574..4a3a794 100755 --- a/would-reformat.sh +++ b/would-reformat.sh @@ -46,7 +46,7 @@ elif [[ $file_type == "python" ]]; then success_retval=0 would_reformat_retval=1 syntax_error_retval=2 -elif [[ $file_type == "golang" ]] ; then +elif [[ $file_type == "golang" ]]; then success_retval=0 would_reformat_retval=1 syntax_error_retval=2 @@ -56,15 +56,15 @@ elif [[ $file_type == "golang" ]] ; then exitval="$?" set -e - if [[ "$exitval" = "$syntax_error_retval" ]] ; then + if [[ "$exitval" = "$syntax_error_retval" ]]; then retval="$exitval" - elif [[ "$out" = "$file" ]] ; then + elif [[ "$out" = "$file" ]]; then retval="$would_reformat_retval" else # success retval="$exitval" fi -elif [[ $file_type == "dart" ]] ; then +elif [[ $file_type == "dart" ]]; then success_retval=0 would_reformat_retval=1 # probably others too :(