devtools: Make linter check LogPrint calls

pull/13153/head
MarcoFalke 7 years ago committed by Wladimir J. van der Laan
parent ff2ad2d569
commit 4b75dcf0ec

@ -13,12 +13,13 @@
# ignored # ignored
UNTERMINATED_LOGS=$(git grep "LogPrintf(" -- "*.cpp" | \ UNTERMINATED_LOGS=$(git grep --extended-regexp "LogPrintf?\(" -- "*.cpp" | \
grep -v '\\n"' | \ grep -v '\\n"' | \
grep -v "/\* Continued \*/" | \ grep -v "/\* Continued \*/" | \
grep -v "LogPrint()" | \
grep -v "LogPrintf()") grep -v "LogPrintf()")
if [[ ${UNTERMINATED_LOGS} != "" ]]; then if [[ ${UNTERMINATED_LOGS} != "" ]]; then
echo "All calls to LogPrintf() should be terminated with \\n" echo "All calls to LogPrintf() and LogPrint() should be terminated with \\n"
echo echo
echo "${UNTERMINATED_LOGS}" echo "${UNTERMINATED_LOGS}"
exit 1 exit 1

Loading…
Cancel
Save