java 如何为使用 sonarqube-5.4 和 maven 报告的问题生成 html 报告?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/36147724/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to generate html report for issues reported using sonarqube-5.4 and maven?
提问by S.B
I have checked the link:sonarqube issues report,but not clear on how to achive it during maven build.
我检查了链接:sonarqube 问题报告,但不清楚如何在 maven 构建期间实现它。
采纳答案by Simon Brandhof - SonarSource
As documented the Issues Report Plugin is not compatible with versions 5.1 and greater. SonarLint for Command-Lineshould be used to get the same feature. It is simple to enable with Maven:
正如所记录的,问题报告插件与 5.1 及更高版本不兼容。应使用命令行的 SonarLint来获得相同的功能。使用 Maven 启用很简单:
mvn sonar:sonar -Dsonar.analysis.mode=preview -Dsonar.issuesReport.html.enable=true
Paths to the generated HTML reports are displayed in logs:
生成的 HTML 报告的路径显示在日志中:
[INFO] HTML Issues Report generated: /xxx/target/sonar/issues-report/issues-report.html
[INFO] Light HTML Issues Report generated: /xxx/target/sonar/issues-report/issues-report-light.html
[INFO] ANALYSIS SUCCESSFUL