as jcenter()下载缓慢

第一种反复搞定

第一种方法
使用开源中国的maven库
阿里云的(速度飞快):http://maven.aliyun.com/nexus/content/groups/public/

替换项目根目录下build.gradle中的

  repositories {
          jcenter()
    }
为:

 repositories {
        maven{url 'http://maven.aliyun.com/nexus/content/groups/public/'}
    }

第二种方法
修改https为 http协议下载http://jcenter/bintray.com/替换项目根目录下build.gradle中的

 repositories {
          jcenter()
    }
为:

    repositories {
       jcenter(){ url 'http://jcenter.bintray.com/'}
    }
解决Android studio遇见Could not find common.jar (android.arch.core:common:1.0.0).错误

不知道怎么回事就发生的错误,翻墙找到的解决方法,如下:
Error:Could not find common.jar (android.arch.core:common:1.0.0).
Searched in the following locations:
    https://jcenter.bintray.com/android/arch/core/common/1.0.0/common-1.0.0.jar

修改的位置:Gradle Scripts --->build.gradle(Project:项目名)--->allprojects{}里面;
解决方法:
    repositories {
        maven{url"https://maven.google.com"}
        jcenter()
        maven{url 'https://jitpack.io'}
    }


————————————————
版权声明:本文为CSDN博主「珍惜现再」的原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接及本声明。
原文链接:https://blog.csdn.net/u014649598/article/details/91437130

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章