Add gradle configuration "use.maven.local"

This commit is contained in:
Him188 2021-08-16 18:08:35 +08:00
parent 8663978d65
commit da9dd1e353
3 changed files with 13 additions and 4 deletions

View File

@ -15,8 +15,10 @@ import org.jetbrains.kotlin.gradle.plugin.KotlinPlatformType
buildscript { buildscript {
repositories { repositories {
// mavenLocal() if (System.getProperty("use.maven.local") == "true") {
// maven(url = "https://mirrors.huaweicloud.com/repository/maven") mavenLocal()
}
mavenCentral() mavenCentral()
gradlePluginPortal() gradlePluginPortal()
google() google()
@ -67,8 +69,10 @@ allprojects {
version = Versions.project version = Versions.project
repositories { repositories {
// mavenLocal() // cheching issue cause compiler exception if (System.getProperty("use.maven.local") == "true") {
// maven(url = "https://mirrors.huaweicloud.com/repository/maven") mavenLocal()
}
mavenCentral() mavenCentral()
gradlePluginPortal() gradlePluginPortal()
google() google()

View File

@ -22,3 +22,5 @@ systemProp.org.gradle.internal.publish.checksums.insecure=true
gnsp.disableApplyOnlyOnRootProjectEnforcement=true gnsp.disableApplyOnlyOnRootProjectEnforcement=true
# We may target 15 with Kotlin 1.5 IR # We may target 15 with Kotlin 1.5 IR
mirai.android.target.api.level=24 mirai.android.target.api.level=24
systemProp.use.maven.local=false

View File

@ -9,6 +9,9 @@
pluginManagement { pluginManagement {
repositories { repositories {
if (System.getProperty("use.maven.local") == "true") {
mavenLocal()
}
// mavenLocal() // mavenLocal()
gradlePluginPortal() gradlePluginPortal()
mavenCentral() mavenCentral()