Travis: more appealing thank you message (#3858)
This commit is contained in:
parent
cd431594e2
commit
b072b540a2
1 changed files with 25 additions and 3 deletions
|
@ -2,36 +2,58 @@
|
||||||
|
|
||||||
# Check formatting using clang-format
|
# Check formatting using clang-format
|
||||||
echo "Checking your code using clang-format..."
|
echo "Checking your code using clang-format..."
|
||||||
|
|
||||||
diff="$(./clangify.sh --diff --cf-version)"
|
diff="$(./clangify.sh --diff --cf-version)"
|
||||||
err=$?
|
err=$?
|
||||||
|
|
||||||
case $err in
|
case $err in
|
||||||
1)
|
1)
|
||||||
cat <<EOM
|
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. ***
|
*** Please correct it or run the "clangify.sh" script. ***
|
||||||
*** Then commit and push those changes to this branch. ***
|
*** Then commit and push those changes to this branch. ***
|
||||||
*** Check our CONTRIBUTING.md file for more details. ***
|
*** Check our CONTRIBUTING.md file for more details. ***
|
||||||
*** ***
|
*** ***
|
||||||
*** Thank you ♥ ***
|
*** Thank you ❤️ ***
|
||||||
*** ***
|
*** ***
|
||||||
***********************************************************
|
***********************************************************
|
||||||
|
|
||||||
Used clang-format version:
|
Used clang-format version:
|
||||||
${diff%%
|
${diff%%
|
||||||
*}
|
*}
|
||||||
|
|
||||||
The following changes should be made:
|
The following changes should be made:
|
||||||
${diff#*
|
${diff#*
|
||||||
}
|
}
|
||||||
|
|
||||||
Exiting...
|
Exiting...
|
||||||
EOM
|
EOM
|
||||||
exit 2
|
exit 2
|
||||||
;;
|
;;
|
||||||
|
|
||||||
0)
|
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 "Something went wrong in our formatting checks: clangify returned $err" >&2
|
||||||
|
echo ""
|
||||||
;;
|
;;
|
||||||
esac
|
esac
|
||||||
|
|
Loading…
Reference in a new issue