This version of Android Studio is incompatible with the Gradle Plugin used解決

從github上下載下來的項目,不報錯但一運行報Error running app: This version of Android Studio is incompatible with the Gradle Plugin used.Try disabling Instant Run (or updating either the IDE or the Gradle plugin to the latest version) 百度了好多,結果還是不行,對於我的解決方式做個記錄
提示的錯誤說Gradle與Android Studio不兼容,於是我拿了一個可運行的項目,copy了gradle->wrapper->gradle-wrapper.properties文件的distributionUrl到我update下來的項目,同時也修改了build.gradle的dependencies {
classpath ‘com.android.tools.build:gradle:2.1.3’//添加你自己的gradle
}
然後重新編譯,項目就可以運行了

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