tomasbjerre / violations-lib

Java library for parsing report files from static code analysis.
Apache License 2.0
148 stars 39 forks source link

WIP: DiffParser #95 #102

Closed tomasbjerre closed 3 years ago

tomasbjerre commented 4 years ago

This is work in progress for #95 .

Not sure about how useful this actually is. Perhaps this can be a first step, and next step can be to enhence the Violation model with suggestedChange. So that comment-libraries can implement it.

Was not able to find a good library for parsing unified diffs. The one I eventually tried does have some bugs, https://github.com/java-diff-utils/java-diff-utils/issues/98 https://github.com/java-diff-utils/java-diff-utils/issues/97. API is also strange, https://github.com/java-diff-utils/java-diff-utils/issues/99.

Example patch-files from Spotless or ErrorProne should be added to this PR.