For AI agents: the documentation index is at https://docs.gradle.org/llms.txt. Request any page with the header Accept: text/markdown to get Markdown. User manual pages are also available as Markdown by replacing .html with .md in the URL.

hasPlugin

abstract fun hasPlugin(id: String): Boolean(source)

Returns true if a plugin with the given ID has already been applied or is currently being applied, otherwise false.

In contrast, withPlugin and hasPlugin only consider a plugin once its application has completed.

Return

true if the plugin has been applied or is being applied

Since

2.3

Parameters

id

the plugin ID. See findPlugin for details about this parameter.