解决android studio添加module时出现Plugin with id 'com.android.application' not found

将project目录下

build.gradle中以下内容复制到moduel中的
build:gradle即可,注意classpath 'com.android.tools.build:gradle:3.1.4'版本信息要一致

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

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

allprojects {
    repositories {
        google()
        jcenter()
    }
}

你可能感兴趣的:(android,知识点)