aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichal Duda <michal.duda@sonarsource.com>2019-08-07 12:39:35 +0200
committerSonarTech <sonartech@sonarsource.com>2019-08-12 20:21:13 +0200
commitd57f3071ec1060dc23c5c4bce542f3d802a252a7 (patch)
tree409cc66cdb3ca7689f4078c84d0cc527d4341987
parent05c8a2e004e9cc17a4d5963a42c835753eefb367 (diff)
downloadsonarqube-d57f3071ec1060dc23c5c4bce542f3d802a252a7.tar.gz
sonarqube-d57f3071ec1060dc23c5c4bce542f3d802a252a7.zip
SONAR-12384 update gradle build
-rw-r--r--build.gradle37
-rw-r--r--server/sonar-docs/build.gradle60
-rw-r--r--sonar-application/build.gradle35
3 files changed, 109 insertions, 23 deletions
diff --git a/build.gradle b/build.gradle
index c6be9249ca0..f5d51fd4db8 100644
--- a/build.gradle
+++ b/build.gradle
@@ -33,8 +33,14 @@ if (project.hasProperty('time-tracker')) {
}
}
-// Analyze SonarQube with SonarQube!
-ext.versionInSources = version
+ext {
+ slangVersion = '1.5.0.315'
+ dotnetVersion = '7.15.0.8572'
+
+ // Analyze SonarQube with SonarQube!
+ versionInSources = version
+}
+
apply plugin: 'org.sonarqube'
sonarqube {
properties {
@@ -108,6 +114,33 @@ subprojects {
// Central place for definition dependency versions and exclusions.
dependencyManagement {
dependencies {
+ // language plugin list
+ dependency 'com.sonarsource.abap:sonar-abap-plugin:3.8.0.2034'
+ dependency 'com.sonarsource.slang:sonar-apex-plugin:1.5.0.315'
+ dependency "org.sonarsource.dotnet:sonar-csharp-plugin:${dotnetVersion}"
+ dependency 'com.sonarsource.cpp:sonar-cfamily-plugin:6.3.0.11371'
+ dependency 'com.sonarsource.cobol:sonar-cobol-plugin:4.4.0.3403'
+ dependency 'org.sonarsource.css:sonar-css-plugin:1.1.1.1010'
+ dependency 'org.sonarsource.flex:sonar-flex-plugin:2.5.1.1831'
+ dependency 'org.sonarsource.go:sonar-go-plugin:1.1.1.2000'
+ dependency 'org.sonarsource.java:sonar-java-plugin:5.13.1.18282'
+ dependency 'org.sonarsource.javascript:sonar-javascript-plugin:5.2.1.7778'
+ dependency "org.sonarsource.slang:sonar-kotlin-plugin:${slangVersion}"
+ dependency 'org.sonarsource.php:sonar-php-plugin:3.2.0.4868'
+ dependency 'com.sonarsource.pli:sonar-pli-plugin:1.10.0.1880'
+ dependency 'com.sonarsource.plsql:sonar-plsql-plugin:3.4.1.2576'
+ dependency 'org.sonarsource.python:sonar-python-plugin:1.14.1.3143'
+ dependency 'com.sonarsource.rpg:sonar-rpg-plugin:2.3.0.1187'
+ dependency "org.sonarsource.slang:sonar-ruby-plugin:${slangVersion}"
+ dependency "org.sonarsource.slang:sonar-scala-plugin:${slangVersion}"
+ dependency 'com.sonarsource.swift:sonar-swift-plugin:4.1.0.3087'
+ dependency 'org.sonarsource.typescript:sonar-typescript-plugin:1.9.0.3766'
+ dependency 'com.sonarsource.tsql:sonar-tsql-plugin:1.4.0.3334'
+ dependency "org.sonarsource.dotnet:sonar-vbnet-plugin:${dotnetVersion}"
+ dependency 'com.sonarsource.plugins.vb:sonar-vb-plugin:2.6.0.1875'
+ dependency 'org.sonarsource.html:sonar-html-plugin:3.1.0.1615'
+ dependency 'org.sonarsource.xml:sonar-xml-plugin:2.0.1.2020'
+
// please keep this list alphabetically ordered
dependencySet(group: 'ch.qos.logback', version: '1.2.3') {
entry 'logback-access'
diff --git a/server/sonar-docs/build.gradle b/server/sonar-docs/build.gradle
index 51b967e54be..d851ab04c60 100644
--- a/server/sonar-docs/build.gradle
+++ b/server/sonar-docs/build.gradle
@@ -1,3 +1,9 @@
+import java.util.regex.Matcher
+import java.util.regex.Pattern
+
+Pattern PLUGIN_NAME_PATTERN = Pattern.compile("(sonar-.*-plugin)(.*)")
+
+
/**
* This module is building the zip file containing the static web site
*/
@@ -8,6 +14,58 @@ sonarqube {
group = 'com.sonarsource.sonarqube'
+configurations {
+ languagePlugin { transitive = false }
+}
+
+dependencies {
+ languagePlugin 'com.sonarsource.abap:sonar-abap-plugin@jar'
+ languagePlugin 'com.sonarsource.slang:sonar-apex-plugin@jar'
+ languagePlugin "org.sonarsource.dotnet:sonar-csharp-plugin@jar"
+ languagePlugin 'com.sonarsource.cpp:sonar-cfamily-plugin@jar'
+ languagePlugin 'com.sonarsource.cobol:sonar-cobol-plugin@jar'
+ languagePlugin 'org.sonarsource.css:sonar-css-plugin@jar'
+ languagePlugin 'org.sonarsource.flex:sonar-flex-plugin@jar'
+ languagePlugin 'org.sonarsource.go:sonar-go-plugin@jar'
+ languagePlugin 'org.sonarsource.java:sonar-java-plugin@jar'
+ languagePlugin 'org.sonarsource.javascript:sonar-javascript-plugin@jar'
+ languagePlugin "org.sonarsource.slang:sonar-kotlin-plugin@jar"
+ languagePlugin 'org.sonarsource.php:sonar-php-plugin@jar'
+ languagePlugin 'com.sonarsource.pli:sonar-pli-plugin@jar'
+ languagePlugin 'com.sonarsource.plsql:sonar-plsql-plugin@jar'
+ languagePlugin 'org.sonarsource.python:sonar-python-plugin@jar'
+ languagePlugin 'com.sonarsource.rpg:sonar-rpg-plugin@jar'
+ languagePlugin "org.sonarsource.slang:sonar-ruby-plugin@jar"
+ languagePlugin "org.sonarsource.slang:sonar-scala-plugin@jar"
+ languagePlugin 'com.sonarsource.swift:sonar-swift-plugin@jar'
+ languagePlugin 'org.sonarsource.typescript:sonar-typescript-plugin@jar'
+ languagePlugin 'com.sonarsource.tsql:sonar-tsql-plugin@jar'
+ languagePlugin "org.sonarsource.dotnet:sonar-vbnet-plugin@jar"
+ languagePlugin 'com.sonarsource.plugins.vb:sonar-vb-plugin@jar'
+ languagePlugin 'org.sonarsource.html:sonar-html-plugin@jar'
+ languagePlugin 'org.sonarsource.xml:sonar-xml-plugin@jar'
+}
+
+task extractAnalyzerDocFiles {
+ doLast {
+ configurations.languagePlugin.files.each {
+ File file = it
+ copy {
+ from(zipTree(file).matching { include 'static/documentation.md' }) {
+ eachFile { fcd ->
+ Matcher m = PLUGIN_NAME_PATTERN.matcher(file.getName())
+ if (m.find()) {
+ fcd.relativePath = new RelativePath(true, m.group(1) + '.md')
+ }
+ }
+ includeEmptyDirs = false
+ }
+ into "$buildDir/tmp/plugin-documentation/"
+ }
+ }
+ }
+}
+
yarn_run {
def docsVersion = version.split("[.-]").take(2).join('.')
environment = [ GATSBY_DOCS_VERSION: docsVersion ]
@@ -48,7 +106,7 @@ task zip(type: Zip) {
}
}
zip.dependsOn yarn_run
-assemble.dependsOn zip
+assemble.dependsOn zip, extractAnalyzerDocFiles
publishing {
publications {
diff --git a/sonar-application/build.gradle b/sonar-application/build.gradle
index 14a5fcd7459..50d72dc63d8 100644
--- a/sonar-application/build.gradle
+++ b/sonar-application/build.gradle
@@ -26,11 +26,6 @@ configurations {
}
}
-ext {
- slangVersion = '1.5.0.315'
- dotnetVersion = '7.15.0.8572'
-}
-
dependencies {
// please keep list ordered
compile 'org.slf4j:slf4j-api'
@@ -58,25 +53,25 @@ dependencies {
bundledPlugin 'org.sonarsource.auth.github:sonar-auth-github-plugin:1.5.0.870@jar'
bundledPlugin 'org.sonarsource.auth.saml:sonar-auth-saml-plugin:1.1.0.181@jar'
- bundledPlugin 'org.sonarsource.css:sonar-css-plugin:1.1.1.1010@jar'
- bundledPlugin "org.sonarsource.dotnet:sonar-csharp-plugin:${dotnetVersion}@jar"
- bundledPlugin "org.sonarsource.dotnet:sonar-vbnet-plugin:${dotnetVersion}@jar"
- bundledPlugin 'org.sonarsource.flex:sonar-flex-plugin:2.5.1.1831@jar'
- bundledPlugin 'org.sonarsource.go:sonar-go-plugin:1.1.1.2000@jar'
- bundledPlugin 'org.sonarsource.html:sonar-html-plugin:3.1.0.1615@jar'
- bundledPlugin 'org.sonarsource.java:sonar-java-plugin:5.13.1.18282@jar'
+ bundledPlugin 'org.sonarsource.css:sonar-css-plugin@jar'
+ bundledPlugin "org.sonarsource.dotnet:sonar-csharp-plugin@jar"
+ bundledPlugin "org.sonarsource.dotnet:sonar-vbnet-plugin@jar"
+ bundledPlugin 'org.sonarsource.flex:sonar-flex-plugin@jar'
+ bundledPlugin 'org.sonarsource.go:sonar-go-plugin@jar'
+ bundledPlugin 'org.sonarsource.html:sonar-html-plugin@jar'
+ bundledPlugin 'org.sonarsource.java:sonar-java-plugin@jar'
bundledPlugin 'org.sonarsource.jacoco:sonar-jacoco-plugin:1.0.2.475@jar'
- bundledPlugin 'org.sonarsource.javascript:sonar-javascript-plugin:5.2.1.7778@jar'
+ bundledPlugin 'org.sonarsource.javascript:sonar-javascript-plugin@jar'
bundledPlugin 'org.sonarsource.ldap:sonar-ldap-plugin:2.2.0.608@jar'
- bundledPlugin 'org.sonarsource.php:sonar-php-plugin:3.2.0.4868@jar'
- bundledPlugin 'org.sonarsource.python:sonar-python-plugin:1.14.1.3143@jar'
- bundledPlugin "org.sonarsource.slang:sonar-kotlin-plugin:${slangVersion}@jar"
- bundledPlugin "org.sonarsource.slang:sonar-ruby-plugin:${slangVersion}@jar"
+ bundledPlugin 'org.sonarsource.php:sonar-php-plugin@jar'
+ bundledPlugin 'org.sonarsource.python:sonar-python-plugin@jar'
+ bundledPlugin "org.sonarsource.slang:sonar-kotlin-plugin@jar"
+ bundledPlugin "org.sonarsource.slang:sonar-ruby-plugin@jar"
bundledPlugin 'org.sonarsource.scm.git:sonar-scm-git-plugin:1.8.0.1574@jar'
bundledPlugin 'org.sonarsource.scm.svn:sonar-scm-svn-plugin:1.9.0.1295@jar'
- bundledPlugin "org.sonarsource.slang:sonar-scala-plugin:${slangVersion}@jar"
- bundledPlugin 'org.sonarsource.typescript:sonar-typescript-plugin:1.9.0.3766@jar'
- bundledPlugin 'org.sonarsource.xml:sonar-xml-plugin:2.0.1.2020@jar'
+ bundledPlugin "org.sonarsource.slang:sonar-scala-plugin@jar"
+ bundledPlugin 'org.sonarsource.typescript:sonar-typescript-plugin@jar'
+ bundledPlugin 'org.sonarsource.xml:sonar-xml-plugin@jar'
}
jar {