Skip to content

Commit

Permalink
Travis: more appealing thank you message (#3858)
Browse files Browse the repository at this point in the history
  • Loading branch information
tooomm authored and ZeldaZach committed Nov 23, 2019
1 parent cd43159 commit b072b54
Showing 1 changed file with 25 additions and 3 deletions.
28 changes: 25 additions & 3 deletions .ci/travis-lint.sh
Expand Up @@ -2,36 +2,58 @@

# Check formatting using clang-format
echo "Checking your code using clang-format..."

diff="$(./clangify.sh --diff --cf-version)"
err=$?

case $err in
1)
cat <<EOM
***********************************************************
*** ***
*** Your code does not comply with our styleguide. ***
*** Your code does not comply with our style guide. ***
*** ***
*** Please correct it or run the "clangify.sh" script. ***
*** Then commit and push those changes to this branch. ***
*** Check our CONTRIBUTING.md file for more details. ***
*** ***
*** Thank you ***
*** Thank you ❤️ ***
*** ***
***********************************************************
Used clang-format version:
${diff%%
*}
The following changes should be made:
${diff#*
}
Exiting...
EOM
exit 2
;;

0)
echo "Thank you for complying with our code standards."
cat <<EOM
***********************************************************
*** ***
*** Your code complies with our style guide! ***
*** ***
*** Awesome 👍 ***
*** ***
***********************************************************
Exiting...
EOM
exit 0
;;

*)
echo ""
echo "Something went wrong in our formatting checks: clangify returned $err" >&2
echo ""
;;
esac

0 comments on commit b072b54

Please sign in to comment.