I have written a settings plugin that I am publishing to a private Artifactory repo. I would like to use a custom Gradle distribution centralize the configuration of our repos. So I have tried to use this init script (in the Kotlin DSL) to achieve that:
settingsEvaluated {
pluginManagement {
repositories {
maven {
url = uri("MY_ARTIFACTORY_REPO")
}
gradlePluginPortal()
}
}
}
The problem is that since settingsEvaluated runs after the project’s settings.gradle.kts script is evaluated, I cannot apply settings plugins from my repo. Is there any earlier way to configure the pluginManagement block such that the settings.gradle.kts file can use those repos?