简体   繁体   English

如何将scalastyle-result.xml转换为可读报告

[英]How to convert scalastyle-result.xml into readable report

I am working on setting up various analysis tool for scala project. 我正在为scala项目设置各种分析工具。 One of them is checkstyle and I am using 'scalastyle' for that purpose. 其中一个是checkstyle,我正在使用'scalastyle'来达到这个目的。

This plugin produces not easily readable scalastyle-result.xml as a result of running. 该插件由于运行而产生不易读取的scalastyle-result.xml。 Is there a way to convert this XML into some other readable format? 有没有办法将此XML转换为其他可读格式? The idea is to generate the report as part of CI (with is not a problem), and also expose the report to the public (ideally in HTML). 我们的想法是将报告生成为CI的一部分(不是问题),并将报告公开给公众(理想情况下是HTML)。

Any other checkstyle tool might work as well if that makes the problem easier to solve. 任何其他checkstyle工具也可以工作,如果这使问题更容易解决。

Thanks, 谢谢,

scalastyle-result.xml has exactly the same format as checkstyle result format - this was done deliberately. scalastyle-result.xml具有与checkstyle结果格式完全相同的格式 - 这是故意完成的。 Anything that works on checkstyle output will work on scalastyle output. 任何适用于checkstyle输出的东西都适用于scalastyle输出。

Using the checkstyle plugin for jenkins, specify "Publish Checkstyle analysis results", use the output file, and you should be good to go. 使用jenkins的checkstyle插件,指定“发布Checkstyle分析结果”,使用输出文件,你应该好好去。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM