aboutsummaryrefslogtreecommitdiff
path: root/scripts
diff options
context:
space:
mode:
authorJeremy Kniager <jeremyk@lunarg.com>2020-03-27 09:24:47 -0600
committerjeremyk-lunarg <jeremyk@lunarg.com>2020-03-30 08:23:05 -0600
commit183d98b488a32b2185919600ad2239cbb6e25d7c (patch)
treea6b1dd0eef01c18e113bbbb2d5bd8a11c4478166 /scripts
parenta860d5d519bbf2f8d518235c4badbb614198eb08 (diff)
downloadusermoji-183d98b488a32b2185919600ad2239cbb6e25d7c.tar.xz
travis: Add clang-format verions output to travis
Updated `.travis.yml` to output the clang-format version before running a clang-format check. Updated `check_code_format.sh` to include a suggestion to check the user's clang-format version if an error occures. Change-Id: I4328350cedb27998bd84a3d675eab51c89fb1a9e
Diffstat (limited to 'scripts')
-rwxr-xr-xscripts/check_code_format.sh4
1 files changed, 4 insertions, 0 deletions
diff --git a/scripts/check_code_format.sh b/scripts/check_code_format.sh
index dde43794..216da478 100755
--- a/scripts/check_code_format.sh
+++ b/scripts/check_code_format.sh
@@ -22,6 +22,8 @@ RED='\033[0;31m'
GREEN='\033[0;32m'
NC='\033[0m' # No Color
+clang-format --version
+
FILES_TO_CHECK=$(git diff --name-only master | grep -v -E "^include/vulkan" | grep -E ".*\.(cpp|cc|c\+\+|cxx|c|h|hpp)$")
if [ -z "${FILES_TO_CHECK}" ]; then
@@ -37,5 +39,7 @@ if [ -z "${FORMAT_DIFF}" ]; then
else
echo -e "${RED}Found formatting errors!${NC}"
echo "${FORMAT_DIFF}"
+ echo "Be sure you are using the following version of clang-format:"
+ clang-format --version
exit 1
fi