Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add missing github & gitlab reportfile options #978

Merged
merged 3 commits into from Aug 26, 2022

Conversation

koenhendriks
Copy link
Contributor

@koenhendriks koenhendriks commented Aug 26, 2022

Type: bugfix / feature
Fix #977
Breaking change: no

The new supported reports for gitlab and github are missing from the --reportfile- Command line option. I found this issue when I wanted to report using ansi in the command line and export a report file for gitlab's CI. This is useful for end-users as the CI shows a nice report using ansi and the artifact generated by the --reportfile can be parsed by Github/Gitlab

This MR fixes the missing --report-file option for both gitlab and github.

Before MR:

phpmd app,tests ansi ./phpmd-ruleset.xml --reportfile-github report-github.json --reportfile-gitlab report-gitlab.json

No report-github.json or report-gitlab.json was created.

After MR:

phpmd app,tests ansi ./phpmd-ruleset.xml --reportfile-github report-github.json --reportfile-gitlab report-gitlab.json

report-gitlab.json is created with gitlab as report render.
report-github.json is created with github as report render.

AJenbo
AJenbo previously approved these changes Aug 26, 2022
@codecov-commenter
Copy link

Codecov Report

Merging #978 (643be6e) into master (eaa8e47) will decrease coverage by 0.06%.
The diff coverage is 33.33%.

@@             Coverage Diff              @@
##             master     #978      +/-   ##
============================================
- Coverage     88.65%   88.58%   -0.07%     
- Complexity     1055     1057       +2     
============================================
  Files            95       95              
  Lines          2661     2663       +2     
============================================
  Hits           2359     2359              
- Misses          302      304       +2     
Impacted Files Coverage Δ
src/main/php/PHPMD/TextUI/CommandLineOptions.php 71.42% <33.33%> (-0.67%) ⬇️

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

@AJenbo AJenbo merged commit 791596a into phpmd:master Aug 26, 2022
@kylekatarnls kylekatarnls added this to the 2.13.0 milestone Aug 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

Missing Gitlab report/renderer in latest version.
4 participants