Fix publishing to Gradle Plugin Portal #3031
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This seems to be a regression from #2912. It was blocking the release, but I commited this fix directly into the release branch, so no rush now.
Without this change, running
./gradlew publishPlugins
results in:With this change, the artifacts are built and published as expected (well, time will tell).
As far as I understand, we need to define the plugin use in the root project so that it can be used later on in the Gradle runner:
dokka/runners/gradle-plugin/build.gradle.kts
Line 7 in 2b73ddd
If the plugin application is removed from the root project, then the line above in the Gradle runner will fail to resolve the plugin ("plugin was not found in any of the following sources").
So I'm not sure that what I'm suggesting is the best fix, looks like it could be improved, but it works for now. Perhaps, it should be revisited in #2919 or #3030.
If a better alternative is suggested, I can try to implement it as part of this PR, but as long as it doesn't take a lot of time or a lot of re-writing - then it's best addressed separately.