Is it possible to specify a filter file for FindBugs using M9 and the built-in plugin?

I’m using M9 and the new FindBugs plugin. I need to specify a filter file (a sub-set of my Sonar rules) for FindBugs to use. In looking through the docs, I do not see any reference to a filter file (but I’ve overlooked some things here lately). Is this currently possible? If not, will it be in 1.0?



Not yet, but I’m working on a pull request right now, it should be done in a few days. It’ll include excludeFilter and includeFilter.

Hello Jamie, at the moment its not possible to pass a filter file to the built-in findbugs plugin. You can use ‘exclude’ and ‘include’ of FileCollection to exclude specific files from being analyzed.

@Justin FYI: We refactored some stuff in the gradle Findbugs task related to

regards, René

@Jamie includeFilter and excludeFilter are what you’re looking for. effort, reportingLevel, visitors, and omitVisitors will also be supported.

@Rene I had my pull request all ready to go, then I saw those GRADLE-2167 changes, so I had to refactor a bit. I had an issue with FindBugs never finishing, but that was FindBugs specific and I got past it. It probably could use a few more integration tests, but I don’t want to get into the business of testing FindBugs functionality. Submitted pull request:

Hey justin, thanks for the pull request. I’ll hopefully find the time to have a look at it soon.

regards, René

Excellent! Thanks Justin.