File tree Expand file tree Collapse file tree 1 file changed +13
-1
lines changed
Expand file tree Collapse file tree 1 file changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -29,6 +29,10 @@ FLAKE_RETVAL=$?
2929FLAKE_CYTHON=` flake8 --config=python/.flake8.cython`
3030FLAKE_CYTHON_RETVAL=$?
3131
32+ # Run clang-format and check for a consistent code format
33+ CLANG_FORMAT=` python cpp/scripts/run-clang-format.py 2>&1 `
34+ CLANG_FORMAT_RETVAL=$?
35+
3236# Output results if failure otherwise show pass
3337if [ " $ISORT_RETVAL " != " 0" ]; then
3438 echo -e " \n\n>>>> FAILED: isort style check; begin output\n\n"
6266 echo -e " \n\n>>>> PASSED: flake8-cython style check\n\n"
6367fi
6468
65- RETVALS=($ISORT_RETVAL $BLACK_RETVAL $FLAKE_RETVAL $FLAKE_CYTHON_RETVAL )
69+ if [ " $CLANG_FORMAT_RETVAL " != " 0" ]; then
70+ echo -e " \n\n>>>> FAILED: clang format check; begin output\n\n"
71+ echo -e " $CLANG_FORMAT "
72+ echo -e " \n\n>>>> FAILED: clang format check; end output\n\n"
73+ else
74+ echo -e " \n\n>>>> PASSED: clang format check\n\n"
75+ fi
76+
77+ RETVALS=($ISORT_RETVAL $BLACK_RETVAL $FLAKE_RETVAL $FLAKE_CYTHON_RETVAL $CLANG_FORMAT_RETVAL )
6678IFS=$' \n '
6779RETVAL=` echo " ${RETVALS[*]} " | sort -nr | head -n1`
6880
You can’t perform that action at this time.
0 commit comments