From: azv Date: Wed, 30 Nov 2016 10:31:07 +0000 (+0300) Subject: Add script for checking coding style during Jenkins build procedure X-Git-Tag: V_2.6.0~34^2~2 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=fdf646422ae47e54cd1b9b5ffb4d4aa62055da7a;p=modules%2Fshaper.git Add script for checking coding style during Jenkins build procedure --- diff --git a/CPPLINT.cfg b/CPPLINT.cfg index 2905e7513..4eaf07162 100644 --- a/CPPLINT.cfg +++ b/CPPLINT.cfg @@ -1,7 +1,6 @@ set noparent linelength=100 -filter=-,+whitespace/line_length -exclude_files=.*XAO/.* +filter=-,+whitespace/line_length,+whitespace/end_of_line root=src # whitespace/line_length diff --git a/checkCodingStyle.sh b/checkCodingStyle.sh new file mode 100755 index 000000000..3bd0a414d --- /dev/null +++ b/checkCodingStyle.sh @@ -0,0 +1,13 @@ +#!/bin/bash + +source env.sh + +CPPLINT_ARGS="" +CPPLINT_ARGS="${CPPLINT_ARGS} --verbose=0" +CPPLINT_ARGS="${CPPLINT_ARGS} --recursive" +CPPLINT_ARGS="${CPPLINT_ARGS} --counting=detailed" +CPPLINT_ARGS="${CPPLINT_ARGS} --extensions=h,cpp" +CPPLINT_ARGS="${CPPLINT_ARGS} --exclude=src/XAO/* --exclude=src/XAO/tests/*" +CPPLINT_ARGS="${CPPLINT_ARGS} --output=vs7" + +! cpplint.py ${CPPLINT_ARGS} . 2>&1 | grep -v Done