[gjs: 1/8] CI: substitute line numbers in cppcheck error messages



commit 8c6a5b598ecbbcb0bf6845c07c90705732ef1c51
Author: Philip Chimento <philip chimento gmail com>
Date:   Sat May 26 09:01:25 2018 -0700

    CI: substitute line numbers in cppcheck error messages
    
    In order to make the output of cppcheck diff better, we substitute line
    numbers away not only in the beginning of the line, but also in the error
    message.

 test/test-ci.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/test/test-ci.sh b/test/test-ci.sh
index d2fd9a23..45184602 100755
--- a/test/test-ci.sh
+++ b/test/test-ci.sh
@@ -224,14 +224,14 @@ elif [[ $1 == "CPPCHECK" && "$log_message" != *'[skip cppcheck]'* ]]; then
     do_Print_Labels 'Static code analyzer report '
 
     cppcheck --inline-suppr --enable=warning,performance,portability,information,missingInclude --force -q . 
2>&1 | \
-        tee "$save_dir"/analysis/current-report.txt | sed -E 's/:[0-9]+]/:LINE]/' > /cwd/current-report.txt
+        tee "$save_dir"/analysis/current-report.txt | sed -E 's/:[0-9]+]/:LINE]/g' > /cwd/current-report.txt
     cat "$save_dir"/analysis/current-report.txt
     echo
 
     # Get the code committed at upstream master
     do_Get_Upstream_Master "cppCheck"
     cppcheck --inline-suppr --enable=warning,performance,portability,information,missingInclude --force -q . 
2>&1 | \
-        tee "$save_dir"/analysis/master-report.txt | sed -E 's/:[0-9]+]/:LINE]/' > /cwd/master-report.txt
+        tee "$save_dir"/analysis/master-report.txt | sed -E 's/:[0-9]+]/:LINE]/g' > /cwd/master-report.txt
     echo
 
     # Compare the report with master and fail if new warnings are found


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]