SonarQube常用参数

SonarQube常用的配置参数

无论是使用Maven sonar插件还是Sonar scanner,以下这些常用参数都是通用的。参数摘抄自Analysis Parameters | SonarQube Docs,为了避免翻译引起的歧义,所以参数直接采用官方文档的英文原版内容。

KeyDescriptionDefault
sonar.host.urlthe server URLhttp://localhost:9000
sonar.projectKeyThe project's unique key. Allowed characters are: letters, numbers, -, _, . and :, with at least one non-digit.For Maven projects, this defaults to <groupId>:<artifactId>
sonar.projectNameName of the project that will be displayed on the web interface.<name> for Maven projects, otherwise project key. If not provided and there is already a name in the DB, it won't be overwritten
sonar.projectVersionThe project version.<version> for Maven projects, otherwise "not provided"
sonar.loginThe authentication token or login of a SonarQube user with Execute Analysis permission on the project.
sonar.sourcesComma-separated paths to directories containing main source files.Read from build system for Maven, Gradle, MSBuild projects. Defaults to project base directory when neither sonar.sources nor sonar.tests is provided.
sonar.testsComma-separated paths to directories containing test source files.Read from build system for Maven, Gradle, MSBuild projects. Else default to empty.
sonar.coverage.jacoco.xmlReportPathsPath to JaCoCo XML coverage reports. Path wildcards are supported (see above).
sonar.exclusions不需要执行检查的源文件,支持通配符,可以用逗号连接多个路径。
sonar.test.exclusions不需要执行检查的测试源文件,支持通配符,可以用逗号连接多个路径。
  • 1
    点赞
  • 3
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值