Search in sources :

Example 1 with Finalize

use of org.gradle.model.Finalize in project gradle by gradle.

the class MavenPluginPublishingRules method addMarkerPublications.

@Finalize
public void addMarkerPublications(PublishingExtension publishing, GradlePluginDevelopmentExtension pluginDevelopment) {
    if (!pluginDevelopment.isAutomatedPublishing()) {
        return;
    }
    PublicationContainer publications = publishing.getPublications();
    NamedDomainObjectContainer<PluginDeclaration> declaredPlugins = pluginDevelopment.getPlugins();
    for (PluginDeclaration declaration : declaredPlugins) {
        createMavenMarkerPublication(declaration, (MavenPublication) publications.getByName("pluginMaven"), publications);
    }
}
Also used : PluginDeclaration(org.gradle.plugin.devel.PluginDeclaration) PublicationContainer(org.gradle.api.publish.PublicationContainer) Finalize(org.gradle.model.Finalize)

Example 2 with Finalize

use of org.gradle.model.Finalize in project gradle by gradle.

the class IvyPluginPublishingRules method addMarkerPublications.

@Finalize
public void addMarkerPublications(PublishingExtension publishing, GradlePluginDevelopmentExtension pluginDevelopment) {
    if (!pluginDevelopment.isAutomatedPublishing()) {
        return;
    }
    PublicationContainer publications = publishing.getPublications();
    NamedDomainObjectContainer<PluginDeclaration> declaredPlugins = pluginDevelopment.getPlugins();
    for (PluginDeclaration declaration : declaredPlugins) {
        createIvyMarkerPublication(declaration, (IvyPublication) publications.getByName("pluginIvy"), publications);
    }
}
Also used : PluginDeclaration(org.gradle.plugin.devel.PluginDeclaration) PublicationContainer(org.gradle.api.publish.PublicationContainer) Finalize(org.gradle.model.Finalize)

Aggregations

PublicationContainer (org.gradle.api.publish.PublicationContainer)2 Finalize (org.gradle.model.Finalize)2 PluginDeclaration (org.gradle.plugin.devel.PluginDeclaration)2