From 7e2d6156ee09a4b00fb6e1334d078f602273cf60 Mon Sep 17 00:00:00 2001 From: azv Date: Tue, 29 Nov 2016 14:36:09 +0300 Subject: [PATCH] Add cpplint to products for checking Jenkins build procedure --- env_linux.sh | 7 ++++++- findEndLines.sh | 6 ++++-- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/env_linux.sh b/env_linux.sh index 8148a1462..e75fec9c5 100644 --- a/env_linux.sh +++ b/env_linux.sh @@ -2,7 +2,7 @@ # This script uses: # -# SHAPER_PDIR - path of PRODUCTS for SHAPER (SolveSpace, lcov) +# SHAPER_PDIR - path of PRODUCTS for SHAPER (SolveSpace, lcov, cpplint) # SHAPER_ROOT_DIR - path of SHAPER installation for path in SHAPER_PDIR SHAPER_ROOT_DIR; do @@ -36,6 +36,11 @@ export LCOV_ROOT_DIR=${SHAPER_PDIR}/lcov-1.11 export PATH=${LCOV_ROOT_DIR}/bin:${PATH} ## +#------ cpplint ------ +export CPPLINT_ROOT_DIR=${SHAPER_PDIR}/cpplint-1.3.0 +export PATH=${CPPLINT_ROOT_DIR}:${PATH} +## + #------ OCCT ------ # Defaults export CSF_PluginDefaults=${CAS_ROOT_DIR}/src/StdResource diff --git a/findEndLines.sh b/findEndLines.sh index b6e51e282..4f3a19fa6 100755 --- a/findEndLines.sh +++ b/findEndLines.sh @@ -1,7 +1,9 @@ #!/bin/bash +source env.sh + find . \( -name "*.h" -o -name "*.cpp" \) -exec cpplint.py --filter=-,+whitespace/end_of_line --verbose=0 --counting=detailed {} \+ 2>&1 | grep -v Done | tee ./tofix -python correction_auto_2.py --cpplint_output_file ./tofix +#python correction_auto_2.py --cpplint_output_file ./tofix -rm ./tofix \ No newline at end of file +rm ./tofix -- 2.39.2