-
Notifications
You must be signed in to change notification settings - Fork 419
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Dokka 2.0 migration dokkaJavadoc issue #3988
Comments
FYI, full gradle file and project are here: https://github.com/driessamyn/kapper/blob/fix-dokka/lib/build.gradle.kts |
Any update on this or guidance on how v2 can be used? It's a bit odd it was released as a stable version, but it's spewing warnings at me to upgrade with it doesn't seem like the V2 API (or docs) are complete? |
Hi @driessamyn, thanks for reporting the issue. I've checked the Kapper project and I reproduced error you reported. FixTo collect the generated docs into a JAR use different tasks:
// lib/build.gradle.kts
// ...
tasks.register<Jar>("dokkaHtmlJar") {
dependsOn(tasks.dokkaHtml)
from(tasks.dokkaGeneratePublicationHtml.flatMap { it.outputDirectory })
archiveClassifier.set("html-docs")
}
tasks.register<Jar>("dokkaJavadocJar") {
dependsOn(tasks.dokkaJavadoc)
from(tasks.dokkaGeneratePublicationJavadoc.flatMap { it.outputDirectory })
archiveClassifier.set("javadoc")
} After this I was able to run ![]() DetailsThe tasks
Please note that DGPv2 is experimental and is currently not stable. At present there is an example demonstrating how to define the JAR tasks for Dokka HTML and Javadoc when using DPGv2 mode, but it is not yet referenced in the documentation. https://github.com/Kotlin/dokka/blob/v2.0.0/examples/gradle-v2/library-publishing-example/build.gradle.kts#L12-L22 When DGPv2 is released as stable we will update the docs to demonstrate how to produce the docs into JARs. |
Thanks @adam-enko . |
Describe the bug
I am converting my project to Dokka 2, follwoing the documentation and running into a couple of issues.
gradle dokkaJavadoc
executes succssfully but does not generate anything.Adding
as indicated in the docs here and running
gradle dokkaJavadocJar
gives the following error:The same error is produced for the
dokkaHtmlJar
example.Expected behaviour
gradle dokkaJavadoc
to generate javadocsgradle dokkaJavadocJar
to complete successfully.To Reproduce
gradle dokkaJavadoc
gradle dokkaJavadocJar
Dokka configuration
Installation
The text was updated successfully, but these errors were encountered: