diff --git a/.gitlab-ci.yml b/.gitlab-ci.yml index 7d5c8059d0dfcad710418b55d3720fe6ce1222b9..d55a7e23c4f50a038e6d8da67f854a4065c70d95 100644 --- a/.gitlab-ci.yml +++ b/.gitlab-ci.yml @@ -2,10 +2,31 @@ image: gitlab-registry.cern.ch/scouting-demonstrator/scouting-docker-images/scda check_formatting: stage: check - image: gitlab-registry.cern.ch/scouting-demonstrator/scouting-docker-images/scouting-devtools:1.0.0 + image: gitlab-registry.cern.ch/scouting-demonstrator/scouting-docker-images/scouting-devtools:1.1.1 script: - find src/ -iname '*.h' -o -iname '*.cc' | xargs clang-format --style=file --dry-run -Werror || (printf "Please reformat your code using the command\ngit clang-format\n\nafter staging your files with \`git add\` or\n\nclang-format -i [your files]\n" && exit 1) +code_quality-cppcheck: + stage: check + image: gitlab-registry.cern.ch/scouting-demonstrator/scouting-docker-images/scouting-devtools:1.1.1 + script: + - cppcheck --xml --enable=all ./src 2> cppcheck_out.xml + - cppcheck-codequality --input-file cppcheck_out.xml --output-file cppcheck.json + artifacts: + reports: + codequality: cppcheck.json + +code_quality-lizard: + stage: check + image: gitlab-registry.cern.ch/scouting-demonstrator/scouting-docker-images/scouting-devtools:1.1.1 + script: + - statick --config=/tmp/statick.yaml --level=gitlab src/ + - sed -i 's#/builds/scouting-demonstrator/scdaq/##g' src-gitlab.code-climate.json + artifacts: + reports: + codequality: src-gitlab.code-climate.json + + build_rpm_tag: stage: build only: