通过使用 findbugs 进行分析来过滤 jar 文件
我有一个 jar 文件,我想通过 build.xml 使用 findbugs 对其进行分析。我使用“class location =....jar”-模式。 jar 文件包含多个文件夹,但我只需要分析一个文件夹。我该如何指定呢?提前致谢 !
I have a jar-file, which I want analyze with findbugs through build.xml. I use "class location =....jar" - pattern. The jar-file contains several folders, but I need to analyze only one folder. How can I specify that ? Thanks in advance !
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您需要使用过滤器文件,过滤器文件可以说明要包含、排除哪些文件模式...这里有文档 http://findbugs.sourceforge.net/manual/filter.html
You need to use a filter file, a filter file can say what file patterns to include, exclude among other things... There's documentation here http://findbugs.sourceforge.net/manual/filter.html
findbugs 有一个补丁,增加了对嵌套文件集的支持。您可以将其与 Ant 的
zipfileset
结合起来来过滤您想要的文件夹。该补丁位于findbugs sourceforge 页面
There is a patch for findbugs that adds support for nested filesets. You can probably combine this with Ant's
zipfileset
to filter the folder you want.The patch is on the findbugs sourceforge page.