Could not resolve com.android.tools.build:gradle:1.5.0


FAILURE: Build failed with an exception.


* What went wrong:
A problem occurred configuring root project 'android'.
> Could not resolve all dependencies for configuration ':classpath'.
   > Could not resolve com.android.tools.build:gradle:1.5.0.
     Required by:
         :android:unspecified
      > Could not GET 'https://repo1.maven.org/maven2/com/android/tools/build/gradle/1.5.0/gradle-1.5.0.pom'.
         > peer not authenticated


* Try:


BUILD FAILED

Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

 

解決辦法:

在 ionic platform add android 之后
主動修改 xx\platforms\android 目錄 和 xx\platforms\android\CordovaLib 目錄下的 build.gradle
把 mavenCentral() 改成 

jcenter {
url "http://jcenter.bintray.com/"
}

 


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM