Skip to content

Commit

Permalink
Complete upgrade Dokka to V2 (#2914)
Browse files Browse the repository at this point in the history
Closes #2912
  • Loading branch information
paul-dingemans authored Dec 29, 2024
1 parent e2c50f0 commit e1bb380
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 12 deletions.
20 changes: 8 additions & 12 deletions build-logic/src/main/kotlin/ktlint-dokka.gradle.kts
Original file line number Diff line number Diff line change
@@ -1,20 +1,16 @@
plugins {
`java-library`
id("org.jetbrains.dokka")
// Generates Javadoc documentation
id("org.jetbrains.dokka-javadoc")
}

dokka {
dokkaPublications.javadoc {
outputDirectory.set(layout.buildDirectory.dir("javadoc"))
}
}

java {
withSourcesJar()
withJavadocJar()
}

tasks.dokkaJavadoc {
notCompatibleWithConfigurationCache("https://github.com/Kotlin/dokka/issues/1217")
outputDirectory = layout.buildDirectory.dir("javadoc")
}

tasks.named<Jar>("javadocJar") {
dependsOn(tasks.dokkaJavadoc)
archiveClassifier = "javadoc"
from(tasks.dokkaJavadoc)
}
3 changes: 3 additions & 0 deletions gradle.properties
Original file line number Diff line number Diff line change
Expand Up @@ -23,3 +23,6 @@ org.gradle.caching=true
# The release process of ktlint breaks whenever the configuration cache is enabled as not all gradle tasks fully supports this feature yet.
# As the configuration cache only slightly improves the build performance, it is kept disabled for now.
org.gradle.configuration-cache=false

# Enable helpers for migration to Dokka V2
org.jetbrains.dokka.experimental.gradle.pluginMode=V2EnabledWithHelpers

0 comments on commit e1bb380

Please sign in to comment.