plugins.gradle.org is still redirecting to jcenter.bintray.com
For anyone looking for a workaround, add this to your settings.gradle.kts
:
pluginManagement {
repositories {
mavenCentral()
gradlePluginPortal()
}
}
Details:
In a fresh Kotlin project (Gradle build) in IntelliJ IDEA Community Edition, where I’ve added this section to build.gradle:
repositories {
mavenCentral()
gradlePluginPortal()
}
I’m running ./gradlew --refresh-dependencies
and getting
> Could not resolve all files for configuration ':classpath'.
> Could not resolve org.jetbrains.kotlin:kotlin-gradle-plugin-api:1.7.21.
Required by:
project : > org.jetbrains.kotlin.jvm:org.jetbrains.kotlin.jvm.gradle.plugin:1.7.21 > org.jetbrains.kotlin:kotlin-gradle-plugin:1.7.21
> Could not resolve org.jetbrains.kotlin:kotlin-gradle-plugin-api:1.7.21.
> Could not get resource 'https://plugins.gradle.org/m2/org/jetbrains/kotlin/kotlin-gradle-plugin-api/1.7.21/kotlin-gradle-plugin-api-1.7.21.pom'.
> Could not HEAD 'https://jcenter.bintray.com/org/jetbrains/kotlin/kotlin-gradle-plugin-api/1.7.21/kotlin-gradle-plugin-api-1.7.21.pom'.
> PKIX path validation failed: java.security.cert.CertPathValidatorException: validity check failed
https://plugins.gradle.org/m2/org/jetbrains/kotlin/kotlin-gradle-plugin-api/1.7.21/kotlin-gradle-plugin-api-1.7.21.pom
returns status code 303 "See Other"
redirecting to
https://jcenter.bintray.com/org/jetbrains/kotlin/kotlin-gradle-plugin-api/1.7.21/kotlin-gradle-plugin-api-1.7.21.pom