Example for Brakeman
Split from #31
I don't find a checkstyle formatter for brakeman, https://github.com/presidentbeef/brakeman/blob/master/OPTIONS.md#output-options
So we can use Saddler::Reporter::Github's PullRequestComment.
brakeman -f text \
| saddler report \
--reporter Saddler::Reporter::Github::PullRequestComment
We want the converter from brakeman output to checkstyle.
Please try this.
@sanemat Brakeman can not use PullRequestReviewComment by 2 reasons. first, ruby-saddler-reporter-github check matching the warned line and the changed line, but brakeman's warning often not match those(like a Attribute Restriction ). second, brakeman not return warning positions(columns).
So, this patch will solution that, but not elegant. I hope update by you better way 😃
I forgot 😅
My usage is below
git diff -z --name-only \
| xargs -0 -n999 | tr ' ' ',' \
| xargs -n999 bundle exec brakeman -f json --only-files \
| bundle exec brakeman_translate_checkstyle_format translate \
| bundle exec saddler report --require saddler/reporter/github --reporter Saddler::Reporter::Github::PullRequestReviewComment
brakeman_translate_checkstyle_format is exist!
@m-kubo Awesome!!!!