Created
August 24, 2020 09:59
-
-
Save alinetskyi/85f399e99b82bdf507eade69fd2444d2 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
# To use add to `.git/hooks/` | |
# Should be named `pre-push` | |
# Make executable with `chmod +x` | |
flutter analyze | |
RESULT=$? | |
if [ $RESULT -eq 0 ]; then | |
echo success | |
else | |
echo "Fix your problems man!" | |
exit 1 | |
fi | |
flutter test --coverage | |
RESULT=$? | |
if [ $RESULT -eq 0 ]; then | |
echo success | |
else | |
echo "Fix your problems man!" | |
exit 1 | |
fi | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment