Skip to content

Commit

Permalink
Fix support for loading onlyAnalyze classes/packages from specified f…
Browse files Browse the repository at this point in the history
…ile to handle maven modules correctly by using resourceHelper.
  • Loading branch information
Rahul-Khandelwal committed Nov 24, 2023
1 parent 57fa199 commit ff7d91a
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -934,7 +934,7 @@ class SpotBugsMojo extends AbstractMavenReport implements SpotBugsPluginsTrait {
if (onlyAnalyze) {
args << "-onlyAnalyze"
args << Arrays.stream(onlyAnalyze.split(",")).map {
it.startsWith("file:") ? Files.lines(Paths.get(it.substring(5))).collect(Collectors.joining(",")) : it
it.startsWith("file:") ? Files.lines(resourceHelper.getResourceFile(it.substring(5)).toPath()).collect(Collectors.joining(",")) : it
}.collect(Collectors.joining(","))
}

Expand Down

0 comments on commit ff7d91a

Please sign in to comment.