Files
Vasily 201cb40359 Add variable for clang-tidy name when building on Linux
Travis has the correct clang-tidy version of 7, while CircleCI needs
clang-tidy-7.
2019-06-24 19:21:14 +02:00

21 lines
317 B
Bash
Executable File

set +e
if [[ -z $CLANG_TIDY_EXECUTABLE ]]; then
CLANG_TIDY_EXECUTABLE='clang-tidy'
fi
$CLANG_TIDY_EXECUTABLE --version
ERROR=0
for file in $(find ../src -name "*.cpp"); do
echo $file
$CLANG_TIDY_EXECUTABLE $file
EXIT=$?
if [[ $EXIT != 0 ]]; then
ERROR=1
fi
done
set -e
exit $ERROR