Closed dgmartin closed 2 years ago
That's intentional, use the plugin id (com.github.triplet.play) to apply it.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
The Scenario:
I'm working on an internal plugin that among other things manually adds multiple plugins to a single project and configures them without the need for any extra code in the build.gradle script. This internal plugin is then applied to multiple internal projects reducing the need for duplicate build code. I'm trying to add the Gradle Publisher Plugin via the PluginManager as follows:
The Problem:
It seems the PlayPublisherPlugin class has been marked as "internal" (see below). This makes it impossible to reference outside of the project. The code above will fail because it cannot even see PlayPublisherPlugin as available. https://github.com/Triple-T/gradle-play-publisher/blob/22a13750ce46c2d0a250a28fa4cd0b8d586f7cce/play/plugin/src/main/kotlin/com/github/triplet/gradle/play/PlayPublisherPlugin.kt#L65
The Solution:
While I understand the need to lock down internal code from being altered I would argue that this Class is meant to be public facing. If you look at other industry leaders you can see that their "Plugin" class extensions are not set to private or internal:
The request here is to set the PlayPublisherPlugin class from "internal" to "public" in order to allow for access by an external source. Any critical code should be moved to a separate internal class if deemed necessary but I believe the Plugin extension should be public to allow for manual usage as described above.
If you disagree I'd love to better understand your reasoning as a different solution may arise.