Error:(2, 0) Plugin with id 'com.github.dcendents.android-maven' not found解決辦法


導入開源項目的時候老是報這個錯

Error:(2, 0) Plugin with id 'com.github.dcendents.android-maven' not found

 

解決辦法:

首先在Project下那個build.grade里面添加全局依賴
buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:1.5.0'  //1.自動化maven打包插件  classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'  //2.自動上傳至Bintray平台插件  classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.0"  // NOTE: Do not place your application dependencies here; they belong  // in the individual module build.gradle files  } }

按順序來,先添加
classpath 'com.github.dcendents:android-maven-gradle-plugin:1.3'
添加完之后同步下,Android Studio下面的Event Log會出現com.jfrog.bintray not found的錯誤提示,maven那個錯誤提示已經沒有了
這時候再添加
classpath "com.jfrog.bintray.gradle:gradle-bintray-plugin:1.0"
點同步,等待同步完成


免責聲明!

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



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