Selaa lähdekoodia

Added intellij plugin to gradle build.

Luke Taylor 15 vuotta sitten
vanhempi
commit
ed447f63f6
1 muutettua tiedostoa jossa 32 lisäystä ja 0 poistoa
  1. 32 0
      build.gradle

+ 32 - 0
build.gradle

@@ -1,5 +1,14 @@
 apply plugin: 'base'
 
+buildscript {
+    repositories {
+        mavenRepo urls: 'http://gradle.artifactoryonline.com/gradle/plugins'
+    }
+    dependencies {
+        classpath "org.gradle.plugins:gradle-idea-plugin:0.3"
+    }
+}
+
 allprojects {
     version = '3.1.0.CI-SNAPSHOT'
     releaseBuild = version.endsWith('RELEASE')
@@ -18,6 +27,29 @@ allprojects {
     }
 }
 
+allprojects {
+    apply plugin: 'org.gradle.idea'
+    ideaModule {
+        downloadJavadoc=false
+        excludeDirs.add(buildDir)
+    }
+    def config = configurations.findByName('testRuntime')
+    if (!config) {
+        return
+    }
+}
+
+ideaModule {
+    excludeDirs.add(file('.gradle'))
+    excludeDirs.add(file('buildSrc/build'))
+    excludeDirs.add(file('buildSrc/.gradle'))
+}
+
+ideaProject {
+    wildcards += ['?*.gradle']
+    javaVersion = '1.6'
+}
+
 configure(javaProjects) {
     apply from: "$rootDir/gradle/javaprojects.gradle"
     apply from: "$rootDir/gradle/maven.gradle"