-
Notifications
You must be signed in to change notification settings - Fork 489
Open
Labels
Description
In Gradle kotlin scripts, spotlessPredeclare is not available as an assessor. In order to use this , one has to access it via the extensions API, e.g. using kotlin's with.
with(extensions["spotlessPredeclare"] as SpotlessExtension) { ... }Looking at the codebase, I noticed the spotlessPredeclare is not created when the plugin is applied.
spotless/plugin-gradle/src/main/java/com/diffplug/gradle/spotless/SpotlessPlugin.java
Lines 51 to 52 in db6a60e
| // setup the extension | |
| project.getExtensions().create(SpotlessExtension.class, SpotlessExtension.EXTENSION, SpotlessExtensionImpl.class, project); |
Maybe it's on purpose and I wonder why, but maybe it's not and maybe this can be added relatively easily.