在 build.gradle.kts 添加 maven 仓库
使用 kotlin script DSL 配置 build.gradle.kts (高版本移动到settings.gradle.kts)时,添加 maven 仓库的方式如下:
html
pluginManagement {
repositories {
maven {
setUrl("https://maven.aliyun.com/repository/google")
}
maven {
setUrl("https://maven.aliyun.com/repository/public")
}
maven {
setUrl("https://maven.aliyun.com/repository/gradle-plugin")
}
google()
mavenCentral()
gradlePluginPortal()
}
}