From 5065c969e9f07086719b44d89686129f7e3504f8 Mon Sep 17 00:00:00 2001 From: "sebastian.sellmair" Date: Thu, 23 Jul 2020 14:06:59 +0200 Subject: Add link to androidx documentation by default for Android projects --- .../src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka') diff --git a/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt b/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt index 2253a975..f6055a8a 100644 --- a/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt +++ b/runners/gradle-plugin/src/main/kotlin/org/jetbrains/dokka/gradle/DokkaTask.kt @@ -16,10 +16,17 @@ import org.jetbrains.dokka.ReflectDsl.isNotInstance import org.jetbrains.dokka.gradle.ConfigurationExtractor.PlatformData import org.jetbrains.dokka.toJsonString import java.io.File +import java.net.URL import java.util.concurrent.Callable open class DokkaTask : AbstractDokkaTask() { private val ANDROID_REFERENCE_URL = Builder("https://developer.android.com/reference/").build() + + private val ANDROIDX_REFERENCE_URL = Builder( + url = URL("https://developer.android.com/reference/kotlin/"), + packageListUrl = URL("https://developer.android.com/reference/androidx/package-list") + ).build() + private val configExtractor = ConfigurationExtractor(project) @Suppress("MemberVisibilityCanBePrivate") @@ -243,6 +250,7 @@ open class DokkaTask : AbstractDokkaTask() { if (project.isAndroidProject() && !config.noAndroidSdkLink) { config.externalDocumentationLinks.add(ANDROID_REFERENCE_URL) + config.externalDocumentationLinks.add(ANDROIDX_REFERENCE_URL) } if (config.platform?.isNotBlank() == true) { -- cgit