简体   繁体   English

如何将SonarLint连接模式用于STS中的自定义配置规则

[英]How to use SonarLint connected mode for custom configured rules in STS

I have a SonarQube server up and running which has custom rules configured which needs to be reflected in SonarLint . 我已经启动并运行了SonarQube服务器,该服务器配置了自定义规则,需要在SonarLint反映出来。 I have run a SonarQube scan, and the projects are being shown in https://localhost:9000 UI screen. 我已经运行了SonarQube扫描,并且项目在https:// localhost:9000 UI屏幕中显示。

lets come to the SonarLint . 让我们来到SonarLint Without binding the project, I am getting issues as per default rules configured in SonarLint . 没有绑定项目,按照SonarLint配置的默认规则,我遇到了问题。

But when I bind the module with the SonarQube project, issues are not showing up. 但是,当我将模块与SonarQube项目绑定时,问题没有出现。 Its not even single violation in any one of class. 在任何一个班级中都没有哪怕一次违反。

Please guide me to use the feature. 请指导我使用该功能。

I think you would have considered below solution already, if not please go throw by below suggestion once and give a try : 我认为您已经考虑过以下解决方案,否则请一次尝试以下建议:

You can use the connected mode to bind your project in the IDE to a project in SonarQube . 您可以使用连接模式将IDE中的项目绑定到SonarQube的项目。 SonarLint will use the same code analyzers and rules as the ones in SonarQube . SonarLint将使用相同的代码分析工具和规则,如那些SonarQube In SonarQube , it's possible to change the quality profile assigned to projects and enable/disable rules also. SonarQube ,可以更改分配给项目的质量配置文件,也enable/disable规则。

More information : http://www.sonarlint.org/intellij/index.html#Connected 详细信息http : //www.sonarlint.org/intellij/index.html#Connected

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

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