converts an xml file containing resharper inspectcode results to a json file that follows the code climate spec.
note, currently only converts to the subset of the code climate spec required for gitlab-ci.
dotnet tool install -g resharper-to-codeclimate
resharper-to-codeclimate results.xml results.json
variables:
DOTNET_PACKAGES: '$CI_PROJECT_DIR\.nuget\packages'
DOTNET_CLI_HOME: '$CI_PROJECT_DIR\.dotnet'
DOTNET_NOLOGO: 'true'
codequality:
stage: codequality
script:
- dotnet tools restore
- jb inspectcode Project.sln -o=results.xml
- resharper-to-codeclimate results.xml results.json
cache:
key:
files:
- .config/dotnet-tools.json
paths:
- .nuget/
artifacts:
when: always
reports:
codequality:
- results.json