GradlePluginDevelopmentExtension

Configuration options for the org.gradle.plugin.devel.plugins.JavaGradlePluginPlugin.

Below is a full configuration example. Since all properties have sensible defaults, typically only selected properties will be configured.

    plugins {
        id 'java-gradle-plugin'
    }

    sourceSets {
        customMain
        functionalTest
    }

    gradlePlugin {
        pluginSourceSet project.sourceSets.customMain
        testSourceSets project.sourceSets.functionalTest
        plugins {
            helloPlugin {
                id  = 'org.example.hello'
                implementationClass = 'org.example.HelloPlugin'
            }
        }
    }

Since

2.13

See also

Constructors

Link copied to clipboard
constructor(project: Project, pluginSourceSet: SourceSet, testSourceSet: SourceSet)
constructor(project: Project, pluginSourceSet: SourceSet, testSourceSets: Array<SourceSet>)

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Functions

Link copied to clipboard
Returns the source sets executing the functional tests with TestKit.
Link copied to clipboard
Whether the plugin should automatically configure the publications for the plugins.
Link copied to clipboard
Configures the declared plugins.
Link copied to clipboard
open fun pluginSourceSet(pluginSourceSet: SourceSet)
Provides the source set that compiles the code under test.
Link copied to clipboard
open fun setAutomatedPublishing(automatedPublishing: Boolean)
Configures whether the plugin should automatically configure the publications for the plugins.
Link copied to clipboard
open fun testSourceSet(testSourceSet: SourceSet)
Adds some source sets to the collection which will be using TestKit.
Link copied to clipboard
open fun testSourceSets(testSourceSets: Array<SourceSet>)
Provides the source sets executing the functional tests with TestKit.