Skip to content

Instantly share code, notes, and snippets.

View Jacknic's full-sized avatar
😆
working

Jacknic Jacknic

😆
working
View GitHub Profile
@Jacknic
Jacknic / init.gradle.kts
Last active June 27, 2024 02:25 — forked from bennyhuo/init.gradle.kts
How to config mirrors for repositories in Gradle without changing the source code of your project?
@file:Suppress("UnstableApiUsage")
import org.gradle.util.GradleVersion
val urlMappingsTencent = mapOf(
"https://repo.maven.apache.org/maven2" to "https://mirrors.tencent.com/nexus/repository/maven-public/",
"https://dl.google.com/dl/android/maven2" to "https://mirrors.tencent.com/nexus/repository/maven-public/",
"https://plugins.gradle.org/m2" to "https://mirrors.tencent.com/nexus/repository/gradle-plugins/"
)