Gradle plugin v2 with versioning plugin requires olderVersionsDir to exist #3966
Labels
bug
runner: gradle plugin v2
Issues fixed by Dokka Gradle Plugin v2 - see https://github.com/Kotlin/dokka/issues/3131
Describe the bug
With the Dokka Gradle plugin v2, using the versioning plugin and configuring
olderVersionsDir
to a directory path that doesn't currently exist, the task:dokkaGeneratePublicationHtml
fails with the error:This was not an error before the v2 Gradle plugin.
Expected behaviour
My project configures the
:dokkaGeneratePublicationHtml
task with adoFirst
lambda that moves the older version directory to the configured path. So the files are present when the task runs, but not before it runs.It should not be an error to configure this path to a currently non-existent directory. It's undesirable to have the empty directory exist in the file system when the code expects it to only exist temporarily while the API docs are being generated.
To Reproduce
Configure a project with the versioning plugin and set
olderVersionsDir
to a non-existent path. Then run:dokkaGenerate
to see the error.Dokka configuration
Configuration of dokka used to reproduce the bug
Installation
Additional context
Reproducible with my library, Kotbase by removing this line of code:
tempOlderDir.mkdir()
.The text was updated successfully, but these errors were encountered: