Reputation: 3275
I'm integrating findbugs in a mixed java/kotlin project. However, as findbugs acts on the generated jar it is finding bugs related to classes generated through kotlin file.
Is there any way to avoid checks on these classes?
Thank you
Upvotes: 11
Views: 2528
Reputation: 85966
Filter based on the <Source>
filter type.
This element matches warnings associated with a particular source file. The name attribute is used to specify the exact or regex match pattern for the source file name.
<FindBugsFilter>
<Match>
<Source name="~.*\.kt"/>
</Match>
</FindBugsFilter>
See: documentation for FindBugs filters and name matching details
Upvotes: 12
Reputation: 14630
I think filter should help in many cases:
<FindBugsFilter>
<Match>
<Class name="*Kt"/>
</Match>
</FindBugsFilter>
I'm not sure that this filter is right, but you should got idea.
Upvotes: 0