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

来源:互联网 发布:linux常用命令手册 编辑:程序博客网 时间:2024/06/05 08:03

从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
}
然后重新编译,项目就可以运行了

1 0