Commit 6e1e4991 authored by GILLES Sebastien's avatar GILLES Sebastien

#1500 CI: add time elapsed in Cppcheck script, and speed it up with -j option.

parent 77d66857
import os
import time
import subprocess
......@@ -11,6 +12,8 @@ if __name__ == "__main__":
cmd = \
[
"cppcheck",
# "-j",
# "4",
"--std=c++17",
"--enable=all",
"-v",
......@@ -31,6 +34,9 @@ if __name__ == "__main__":
FILE=open('morefem-cppcheck.xml', 'w')
subprocess.Popen(cmd, shell=False, stdout=None, stderr=FILE).communicate()
start = time.time()
print("Output written in morefem-cppcheck.xml")
\ No newline at end of file
subprocess.Popen(cmd, shell=False, stdout=None, stderr=FILE).communicate()
end = time.time()
print("Output written in morefem-cppcheck.xml; analysis performed in {} seconds".format(round(end - start, 1)))
\ No newline at end of file
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment