From 56213b9d66a78fdd35c2826c6edc3f36d491ff32 Mon Sep 17 00:00:00 2001 From: Simon Ogorodnik Date: Mon, 29 Jan 2018 19:53:23 +0300 Subject: Update Gradle Kotlin Runtime dependencies version to 1.1 Dokka drops support for Gradle less then 3.5 --- runners/android-gradle-plugin/build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'runners/android-gradle-plugin') diff --git a/runners/android-gradle-plugin/build.gradle b/runners/android-gradle-plugin/build.gradle index 5050fd87..7d286cc7 100644 --- a/runners/android-gradle-plugin/build.gradle +++ b/runners/android-gradle-plugin/build.gradle @@ -13,7 +13,7 @@ tasks.withType(org.jetbrains.kotlin.gradle.tasks.KotlinCompile).all { kotlinOptions { freeCompilerArgs += "-Xjsr305=strict" languageVersion = "1.2" - apiVersion = "1.0" + apiVersion = "1.1" jvmTarget = "1.8" } } -- cgit From 9530cb367eb1ad92b6ca5aa5261e28f76e7d4bad Mon Sep 17 00:00:00 2001 From: Simon Ogorodnik Date: Tue, 20 Feb 2018 00:11:30 +0300 Subject: Update publish-plugin and fix publishing --- build.gradle | 2 +- runners/android-gradle-plugin/build.gradle | 7 +++++++ runners/gradle-plugin/build.gradle | 8 ++++++++ 3 files changed, 16 insertions(+), 1 deletion(-) (limited to 'runners/android-gradle-plugin') diff --git a/build.gradle b/build.gradle index f3e2cc52..ee76c9cb 100644 --- a/build.gradle +++ b/build.gradle @@ -21,7 +21,7 @@ allprojects { classpath 'com.jfrog.bintray.gradle:gradle-bintray-plugin:1.7' classpath 'com.github.jengelman.gradle.plugins:shadow:2.0.1' - classpath "com.gradle.publish:plugin-publish-plugin:0.9.9" + classpath "com.gradle.publish:plugin-publish-plugin:0.9.10" } } diff --git a/runners/android-gradle-plugin/build.gradle b/runners/android-gradle-plugin/build.gradle index 7d286cc7..72d1be9e 100644 --- a/runners/android-gradle-plugin/build.gradle +++ b/runners/android-gradle-plugin/build.gradle @@ -1,3 +1,4 @@ +import com.gradle.publish.DependenciesBuilder import org.jetbrains.CorrectShadowPublishing apply plugin: 'java' @@ -87,6 +88,12 @@ pluginBundle { } } + withDependencies { List list -> + list.clear() + def builder = new DependenciesBuilder() + builder.addUniqueScopedDependencies(list, configurations.shadow, "compile") + } + mavenCoordinates { groupId = "org.jetbrains.dokka" artifactId = "dokka-android-gradle-plugin" diff --git a/runners/gradle-plugin/build.gradle b/runners/gradle-plugin/build.gradle index d3dbae22..661d432b 100644 --- a/runners/gradle-plugin/build.gradle +++ b/runners/gradle-plugin/build.gradle @@ -1,3 +1,5 @@ +import com.gradle.publish.DependenciesBuilder + apply plugin: 'java' apply plugin: 'kotlin' @@ -84,6 +86,12 @@ pluginBundle { } } + withDependencies { List list -> + list.clear() + def builder = new DependenciesBuilder() + builder.addUniqueScopedDependencies(list, configurations.shadow, "compile") + } + mavenCoordinates { groupId = "org.jetbrains.dokka" artifactId = "dokka-gradle-plugin" -- cgit From ab3621abcc468cead0206d3c45f200f6c9ea10b9 Mon Sep 17 00:00:00 2001 From: Simon Ogorodnik Date: Fri, 18 May 2018 12:45:49 +0300 Subject: Enable suppression of generated files for Android plugin 3.2.0-alpha Fix #308 --- core/src/main/kotlin/DokkaBootstrapImpl.kt | 2 +- core/src/main/kotlin/Kotlin/DocumentationBuilder.kt | 2 +- runners/android-gradle-plugin/src/main/kotlin/mainAndroid.kt | 8 ++++++-- 3 files changed, 8 insertions(+), 4 deletions(-) (limited to 'runners/android-gradle-plugin') diff --git a/core/src/main/kotlin/DokkaBootstrapImpl.kt b/core/src/main/kotlin/DokkaBootstrapImpl.kt index 126a0175..aeaca8be 100644 --- a/core/src/main/kotlin/DokkaBootstrapImpl.kt +++ b/core/src/main/kotlin/DokkaBootstrapImpl.kt @@ -69,7 +69,7 @@ class DokkaBootstrapImpl : DokkaBootstrap { languageVersion, apiVersion, cacheRoot, - suppressedFiles.map { File(it) } + suppressedFiles.map { File(it) }.toSet() ) ) } diff --git a/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt b/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt index 17e4bc1a..7b50fff5 100644 --- a/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt +++ b/core/src/main/kotlin/Kotlin/DocumentationBuilder.kt @@ -53,7 +53,7 @@ class DocumentationOptions(val outputDir: String, val languageVersion: String?, val apiVersion: String?, cacheRoot: String? = null, - val suppressedFiles: List = emptyList()) { + val suppressedFiles: Set = emptySet()) { init { if (perPackageOptions.any { it.prefix == "" }) throw IllegalArgumentException("Please do not register packageOptions with all match pattern, use global settings instead") diff --git a/runners/android-gradle-plugin/src/main/kotlin/mainAndroid.kt b/runners/android-gradle-plugin/src/main/kotlin/mainAndroid.kt index f2261120..bd2e88c2 100644 --- a/runners/android-gradle-plugin/src/main/kotlin/mainAndroid.kt +++ b/runners/android-gradle-plugin/src/main/kotlin/mainAndroid.kt @@ -23,8 +23,12 @@ open class DokkaAndroidTask : DokkaTask() { @Input var noAndroidSdkLink: Boolean = false override fun collectSuppressedFiles(sourceRoots: List): List { - val generatedSubpath = "${project.buildDir}/generated/source".replace("/", File.separator) - return sourceRoots.filter { generatedSubpath in it.path }.flatMap { File(it.path).walk().toList() }.map { it.absolutePath } + val generatedRoot = project.buildDir.resolve("generated").absoluteFile + return sourceRoots + .map { File(it.path) } + .filter { it.startsWith(generatedRoot) } + .flatMap { it.walk().toList() } + .map { it.absolutePath } } init { -- cgit