본문 바로가기
ERROR/Android

build.gradle all buildscript {} blocks must appear before any plugins {} blocks in the script error

by 에디83 2022. 10. 26.

buildScript의 위치가 plugins 보다 뒤에 있으면 안된다.

아래처럼 해결

 

buildscript {
    repositories {
        // Make sure that you have the following two repositories
        google()  // Google's Maven repository
        mavenCentral()  // Maven Central repository
    }
    dependencies {
        // Add the dependency for the Google services Gradle plugin
        classpath 'com.google.gms:google-services:4.3.13'
    }
}

plugins {
    id 'com.android.application' version '7.3.0' apply false
    id 'com.android.library' version '7.3.0' apply false
    id 'org.jetbrains.kotlin.android' version '1.7.10' apply false
}

'ERROR > Android' 카테고리의 다른 글

Unresolved reference: POST_NOTIFICATIONS  (0) 2022.10.27

댓글