Commit eb0ad4d4 authored by Tristan Van Berkom's avatar Tristan Van Berkom

.gitlab-ci.yml: Perform some python code analysis with radon

This adds a new job in the prepare stage which can be viewed in
the gitlab CI, and also produces an artifacts with the json metrics.
parent 827a1294
Pipeline #20574457 failed with stages
in 46 seconds
......@@ -58,6 +58,32 @@ source_dist:
paths:
- dist/
analysis:
stage: prepare
script:
- |
pip3 install radon
mkdir analysis
- |
echo "Calculating Maintainability Index"
radon mi -s -j buildstream > analysis/mi.json
radon mi -s buildstream
- |
echo "Calculating Cyclomatic Complexity"
radon cc -a -s -j buildstream > analysis/cc.json
radon cc -a -s buildstream
- |
echo "Calculating Raw Metrics"
radon raw -s -j buildstream > analysis/raw.json
radon raw -s buildstream
artifacts:
paths:
- analysis/
#####################################################
# Test stage #
#####################################################
......
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