天天看點

Error:(1, 1) A problem occurred evaluating project ':app'. > Failed to apply plugin [id 'com.android

使用Android studio rebuild項目時報錯:Error:(1, 1) A problem occurred evaluating project ':app'.

> Failed to apply plugin [id 'com.android.application']

   > Invalid revision: 12.0.2753695 beta 1

這是因為項目的配置由于工具更新或其他原因更改了。

具體配置檔案:項目目錄下的 build.gradle 檔案

檔案中有這樣一段代碼:

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.1.0'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}      

你需要将classpath 的版本改回原來的樣子我之前版本是2.0.0。之後同步即可

繼續閱讀