]> SALOME platform Git repositories - modules/shaper.git/commitdiff
Salome HOME
Add script for checking coding style during Jenkins build procedure
authorazv <artem.zhidkov@opencascade.com>
Wed, 30 Nov 2016 10:31:07 +0000 (13:31 +0300)
committerazv <artem.zhidkov@opencascade.com>
Wed, 30 Nov 2016 10:31:07 +0000 (13:31 +0300)
CPPLINT.cfg
checkCodingStyle.sh [new file with mode: 0755]

index 2905e751360a5378bed7ff094c446e133c68b859..4eaf0716243d77edce1dd34e4de98ecdaaff4d7a 100644 (file)
@@ -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 (executable)
index 0000000..3bd0a41
--- /dev/null
@@ -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