Prepare dokka (#1238)

* Prepare dokka

This updates to Dokka 1.4.10 and prepares for a future with Kotlin rewrite and mkdocs

* Spotless
This commit is contained in:
Zac Sweers
2020-09-25 22:37:13 -04:00
committed by GitHub
parent a1852a7315
commit 44fa05bce1
4 changed files with 28 additions and 16 deletions

3
.gitignore vendored
View File

@@ -25,3 +25,6 @@ obj
.DS_Store
.gradle
# Temporary until generating a docsite
docs/

View File

@@ -16,6 +16,8 @@
import com.diffplug.gradle.spotless.JavaExtension
import org.gradle.jvm.tasks.Jar
import org.jetbrains.dokka.gradle.DokkaTask
import java.net.URL
buildscript {
dependencies {
@@ -24,9 +26,9 @@ buildscript {
}
plugins {
id("com.vanniktech.maven.publish") version "0.12.0" apply false
id("org.jetbrains.dokka") version "0.10.1" apply false
id("com.diffplug.spotless") version "5.5.0"
id("com.vanniktech.maven.publish") version "0.13.0" apply false
id("org.jetbrains.dokka") version "1.4.10" apply false
id("com.diffplug.spotless") version "5.6.0"
}
spotless {
@@ -102,17 +104,11 @@ spotless {
subprojects {
repositories {
mavenCentral()
@Suppress("UnstableApiUsage")
exclusiveContent {
forRepository {
maven {
name = "JCenter"
setUrl("https://jcenter.bintray.com/")
}
}
filter {
includeModule("org.jetbrains.dokka", "dokka-fatjar")
}
jcenter().mavenContent {
// Required for Dokka
includeModule("org.jetbrains.kotlinx", "kotlinx-html-jvm")
includeGroup("org.jetbrains.dokka")
includeModule("org.jetbrains", "markdown")
}
}
@@ -137,5 +133,18 @@ subprojects {
}
}
}
if (name != "codegen" && pluginManager.hasPlugin("org.jetbrains.kotlin.jvm")) {
apply(plugin = "org.jetbrains.dokka")
tasks.named<DokkaTask>("dokkaHtml") {
outputDirectory.set(rootDir.resolve("docs/1.x"))
dokkaSourceSets.configureEach {
skipDeprecated.set(true)
externalDocumentationLink {
url.set(URL("https://square.github.io/okio/2.x/okio/"))
}
}
}
}
}
}

View File

@@ -5,7 +5,7 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,

View File

@@ -5,7 +5,7 @@
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
* https://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,