gradle-native
gradle-native copied to clipboard
Nokee management plugin should allow settings plugin to resolve correctly
Gradle process for resolving settings plugins follow something like this:
- Configure
pluginManagementblock - Read all of
pluginsblock - For each plugin id in
pluginsblock, try to realize them from whatever is in thepluginManagementblock - Then, apply each plugin id
With this process, we cannot do something like this:
plugins {
id 'dev.nokee.nokee-version-management' version 'latest.release'
id 'dev.nokee.xcode-build-adapter'
}
The build will fail because it cannot find dev.nokee.xcode-build-adapter plugin.
To work around this, we could configure the classpath to pull all of Nokee. Then, the settings plugin will be applied using the legacy apply:
plugins {
id 'dev.nokee.nokee-version-management' version 'latest.release'
}
apply plugin: 'dev.nokee.xcode-build-adapter'
We don't like it, but we need something simple for the users, and this is the simplest. The advantage of this approach is allowing users to apply Nokee plugins using legacy apply in allproject/subproject` actions:
gradle.rootProject {
apply plugin: 'dev.nokee.jni-library'
}