注释掉jcenter使用maven仓库阿里云镜像地址即可
buildscript {
repositories {
google()
//jcenter(){ url ‘http://jcenter.bintray.com/’ }
maven{ url ‘http://maven.aliyun.com/nexus/content/groups/public/‘}
}
dependencies {
classpath ‘com.android.tools.build:gradle:3.1.2’
//Gradle Android Maven plugin
classpath ‘com.github.dcendents:android-maven-gradle-plugin:2.0’
//Gradle Bintray Plugin
classpath ‘com.jfrog.bintray.gradle:gradle-bintray-plugin:1.8.0’
}
}
allprojects {
repositories {
google()
//jcenter() { url ‘http://jcenter.bintray.com/’ }
maven { url “https://jitpack.io” }
maven{ url ‘http://maven.aliyun.com/nexus/content/groups/public/‘}
}
}