Skip to content

Instantly share code, notes, and snippets.

@banasiak
Created August 27, 2018 17:23
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
#!/bin/sh
echo "Formatting code..."
./gradlew googleJavaFormat formatKotlin --daemon
status=$?
if [ "$status" = 0 ]; then
echo "Formatting complete - adding files to Git"
git add .
exit 0
else
echo 1>&2 "Unable to format code"
exit 1
fi
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment