INT-3021 - Fix Sonar Build Plan

* Upgrade to gradle 1.6
* Switch from sonar plugin to sonarRunner plugin

INT-3021 - Correct SCM syntax
This commit is contained in:
Gunnar Hillert
2013-05-17 12:25:58 -04:00
committed by Gary Russell
parent d649a9f542
commit 955e3ee282
4 changed files with 29 additions and 39 deletions

View File

@@ -12,6 +12,15 @@ buildscript {
}
}
ext {
linkHomepage = 'http://www.springintegration.org/'
linkCi = 'https://build.springsource.org/browse/INT'
linkIssue = 'https://jira.springsource.org/browse/INT'
linkScmUrl = 'https://github.com/SpringSource/spring-integration'
linkScmConnection = 'git://github.com/SpringSource/spring-integration.git'
linkScmDevConnection = 'git@github.com:SpringSource/spring-integration.git'
}
allprojects {
group = 'org.springframework.integration'
@@ -595,38 +604,18 @@ reference {
sourceDir = file('src/reference/docbook')
}
apply plugin: 'sonar'
apply plugin: 'sonar-runner'
sonar {
if (rootProject.hasProperty('sonarHostUrl')) {
server.url = rootProject.sonarHostUrl
sonarRunner {
sonarProperties {
property "sonar.jacoco.reportPath", "${buildDir.name}/jacoco.exec"
property "sonar.links.homepage", linkHomepage
property "sonar.links.ci", linkCi
property "sonar.links.issue", linkIssue
property "sonar.links.scm", linkScmUrl
property "sonar.links.scm_dev", linkScmDevConnection
property "sonar.java.coveragePlugin", "jacoco"
}
database {
if (rootProject.hasProperty('sonarJdbcUrl')) {
url = rootProject.sonarJdbcUrl
}
if (rootProject.hasProperty('sonarJdbcDriver')) {
driverClassName = rootProject.sonarJdbcDriver
}
if (rootProject.hasProperty('sonarJdbcUsername')) {
username = rootProject.sonarJdbcUsername
}
if (rootProject.hasProperty('sonarJdbcPassword')) {
password = rootProject.sonarJdbcPassword
}
}
project {
dynamicAnalysis = "reuseReports"
withProjectProperties { props ->
props["sonar.core.codeCoveragePlugin"] = "jacoco"
props["sonar.jacoco.reportPath"] = "${buildDir.name}/jacoco.exec"
}
}
logger.info("Sonar parameters used: server.url='${server.url}'; database.url='${database.url}'; database.driverClassName='${database.driverClassName}'; database.username='${database.username}'")
}
task api(type: Javadoc) {
@@ -769,5 +758,5 @@ task dist(dependsOn: assemble) {
task wrapper(type: Wrapper) {
description = 'Generates gradlew[.bat] scripts'
gradleVersion = '1.5'
gradleVersion = '1.6'
}

Binary file not shown.

View File

@@ -1,6 +1,6 @@
#Thu Apr 11 15:10:59 EDT 2013
zipStoreBase=GRADLE_USER_HOME
distributionUrl=http\://services.gradle.org/distributions/gradle-1.5-bin.zip
distributionPath=wrapper/dists
#Thu May 16 22:49:11 EDT 2013
distributionBase=GRADLE_USER_HOME
distributionPath=wrapper/dists
zipStoreBase=GRADLE_USER_HOME
zipStorePath=wrapper/dists
distributionUrl=http\://services.gradle.org/distributions/gradle-1.6-bin.zip

View File

@@ -31,7 +31,7 @@ def customizePom(pom, gradleProject) {
generatedPom.project {
name = gradleProject.description
description = gradleProject.description
url = 'https://github.com/SpringSource/spring-integration'
url = linkHomepage
organization {
name = 'SpringSource'
url = 'http://springsource.org'
@@ -43,10 +43,11 @@ def customizePom(pom, gradleProject) {
distribution 'repo'
}
}
scm {
url = 'https://github.com/SpringSource/spring-integration'
connection = 'scm:git:git://github.com/SpringSource/spring-integration'
developerConnection = 'scm:git:git://github.com/SpringSource/spring-integration'
url = linkScmUrl
connection = 'scm:git:' + linkScmConnection
developerConnection = 'scm:git:' + linkScmDevConnection
}
developers {