Mercurial > public > develkit
comparison metrics.gradle @ 239:60c552fce00d
DEP-13: disable legacy sonar analysis
author | smith@nwoca.org |
---|---|
date | Fri, 21 Oct 2016 18:16:09 +0100 |
parents | d7f0ae9e28af |
children | c8c8766492c5 |
comparison
equal
deleted
inserted
replaced
238:d7f0ae9e28af | 239:60c552fce00d |
---|---|
12 dependencies { | 12 dependencies { |
13 classpath 'me.davesmith:jaranalyzerplugin:0.2.0-SNAPSHOT' | 13 classpath 'me.davesmith:jaranalyzerplugin:0.2.0-SNAPSHOT' |
14 classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.2" | 14 classpath "org.sonarsource.scanner.gradle:sonarqube-gradle-plugin:2.2" |
15 } | 15 } |
16 } | 16 } |
17 | |
18 | 17 |
19 apply plugin: me.davesmith.gradle.plugins.jaranalyzer.JarAnalyzerPlugin | 18 apply plugin: me.davesmith.gradle.plugins.jaranalyzer.JarAnalyzerPlugin |
20 | 19 |
21 jaranalyzer { | 20 jaranalyzer { |
22 dot = true | 21 dot = true |
46 } | 45 } |
47 } | 46 } |
48 | 47 |
49 if (legacySonar) { | 48 if (legacySonar) { |
50 | 49 |
51 apply plugin: "sonar-runner" | 50 task('sonar') << { |
52 ant.property(file: System.getProperty('user.home') + "/.ssdt/sonar.properties") | 51 println "legacy sonar disabled" |
52 } | |
53 | 53 |
54 sonarRunner { | |
55 sonarProperties { | |
56 property "sonar.host.url", "http://sonar.ssdt-ohio.org/" | |
57 property "sonar.jdbc.url", ant.properties['sonar.jdbc.url'] | |
58 property "sonar.jdbc.driverClassName", ant.properties['sonar.jdbc.driverClassName'] | |
59 property "sonar.jdbc.username", ant.properties['sonar.jdbc.username'] | |
60 property "sonar.jdbc.password", ant.properties['sonar.jdbc.password'] | |
61 property "sonar.build-stability.url", "http://bamboo.ssdt-ohio.org/browse/${gradle.bambooPlan}" | |
62 property "sonar.scm.url", "scm:hg:${gradle.hgRepositoryUrl}" | |
63 } | |
64 } | |
65 | |
66 subprojects { | |
67 afterEvaluate { project -> | |
68 | |
69 def groovyProject = project.plugins.hasPlugin('groovy') | |
70 sonarRunner { | |
71 sonarProperties { | |
72 property "sonar.language", groovyProject ? 'grvy' : 'java' | |
73 property "sonar.build-stability.url", "http://bamboo.ssdt-ohio.org/browse/${gradle.bambooPlan}" | |
74 property "sonar.scm.url", "scm:hg:${gradle.hgRepositoryUrl}" | |
75 } | |
76 } | |
77 } | |
78 } | |
79 | |
80 allprojects { | |
81 afterEvaluate { project -> | |
82 project.getTasksByName('sonarRunner',false).each { it.enabled = gradle.branchStream == 'develop' } | |
83 } | |
84 } | |
85 } | 54 } |