我可以*.kt
使用排除文件
<plugin>
<groupId>com.github.spotbugs</groupId>
<artifactId>spotbugs-maven-plugin</artifactId>
<configuration>
<excludeFilterFile>spotbugs-exclude-filter.xml</excludeFilterFile>
</configuration>
</plugin>
并spotbugs-exclude-filter.xml
包含:
<FindBugsFilter>
<Match>
<Source name="~.*\.kt"/>
</Match>
</FindBugsFilter>
但是,由于 spotbugs 在父 pom 中(Java 和 Kotlin 项目都使用),我更喜欢纯 maven 解决方案,因此继承项目不需要额外的 xml 文件。可能吗?