This is the CodeClimate Report Plugin of jQAssistant.
It allows to generate JSON files in the CodeClimate format which can be used to display them e.g. in GitLab merge requests.
For more information on jQAssistant see https://jqassistant.org.
|
Note
|
Despite linking of source locations is implemented by this plugin the generated links are not valid yet. This requires a change in jQAssistant which is scheduled for one of the next releases. |
The plugin must be declared in the jQAssistant configuration:
.jqassistant.yml
jqassistant:
plugins:
- group-id: org.jqassistant.plugin
artifact-id: jqassistant-codeclimate-report-plugin
version: 1.0.0During execution of the analyze task or goal a file jqassistant-code-climate-report.json is created in the report directory. This can be referenced by a GitLab CI configuration:
.gitlab-ci.yml
stages:
- verify
verify:
stage: verify
script:
- mvn verify # the pom.xml must declare executions for the jQAssistant scan and analyze goals
artifacts:
reports:
codequality:
- target/jqassistant/report/codeclimate/jqassistant-codeclimate-report.json.gitlab-ci.yml
stages:
- jQAssistant
verify:
stage: jQAssistant
script:
- jqassistant scan -f java:classpath::build/classes # Scan a Java classes directory
- jqassistant analyze # Execute analysis
artifacts:
reports:
codequality:
- jqassistant/report/codeclimate/jqassistant-codeclimate-report.json