aboutsummaryrefslogtreecommitdiff
path: root/buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts
diff options
context:
space:
mode:
authoraSemy <897017+aSemy@users.noreply.github.com>2023-03-07 23:26:06 +0100
committerGitHub <noreply@github.com>2023-03-07 23:26:06 +0100
commit62c980707d23d2d451c75330f7ed1ba613777cf3 (patch)
tree2dd732bdaa23713d665a07bcc28c2ab152dc8096 /buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts
parentded804e5772399f1495016d598573cb20b673b58 (diff)
downloaddokka-62c980707d23d2d451c75330f7ed1ba613777cf3.tar.gz
dokka-62c980707d23d2d451c75330f7ed1ba613777cf3.tar.bz2
dokka-62c980707d23d2d451c75330f7ed1ba613777cf3.zip
Use buildSrc convention plugins to configure the Dokka subprojects (#2704)
Diffstat (limited to 'buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts')
-rw-r--r--buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts13
1 files changed, 13 insertions, 0 deletions
diff --git a/buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts b/buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts
new file mode 100644
index 00000000..9a193cbb
--- /dev/null
+++ b/buildSrc/src/main/kotlin/org/jetbrains/conventions/dokka.gradle.kts
@@ -0,0 +1,13 @@
+package org.jetbrains.conventions
+
+import org.gradle.kotlin.dsl.invoke
+import org.jetbrains.isLocalPublication
+
+plugins {
+ id("org.jetbrains.dokka")
+}
+
+tasks.dokkaHtml {
+ onlyIf { !isLocalPublication }
+ outputDirectory.set(layout.buildDirectory.dir("dokka").map { it.asFile })
+}