ID가 'com.google.gms.google-services'인 플러그인을 찾을 수 없습니다.
나는 이 링크를 따라 내 앱에 광고를 통합했습니다.그러나 다음 오류가 표시됩니다.

이게 내 빌드야.그래들:
apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'
android {
compileSdkVersion 24
buildToolsVersion "24.0.2"
defaultConfig {
applicationId "com.example.personal.numbermania"
minSdkVersion 10
targetSdkVersion 24
versionCode 1
versionName "1.0"
}
buildTypes {
debug
{
debuggable true
}
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.android.support:design:24.2.1'
compile 'com.google.firebase:firebase-ads:9.6.0'
}
}
광고가 실제 장치에 표시되지 않습니다.나를 도와주세요 이것은 내가 클래스 경로 오류를 업데이트한 후의 나의 오류입니다.
같은 문제가 있었습니다.
종속성을 추가하여 수정됨
classpath 'com.google.gms:google-services:3.0.0'
근본적으로 build.gradle.
https://firebase.google.com/docs/android/setup#manually_add_firebase
Gradle 하기 »pluginsbuild.gradle 이것과 합니다: 편과같, 다음작동니다합한.
plugins {
id "com.android.application" version "7.3.1" apply false
id "com.android.library" version "7.3.1" apply false
id "com.google.gms.google-services" version "4.3.14" apply false
}
그런 다음 모듈에 적용할 수 있습니다.
plugins {
id "com.android.application"
id "com.google.gms.google-services"
}
한, "Gradle 플에의않한는지하존다수, 있하나뛸건습니너거제일러거부인그/▁unless▁may▁the▁remove▁oneskip다"를 제거하거나 건너뛸 수 .buildscript모두 차단하지만 프로젝트 전체 버전 번호를 정의하는 데 유용합니다.buildscript.ext:
buildscript {
ext {
agp_version = '7.3.1'
gms_version = '4.3.14'
}
}
plugins {
id 'com.android.application' version "$agp_version" apply false
id 'com.android.library' version "$agp_version" apply false
id "com.google.gms.google-services" version "$gms_version" apply false
}
더하다classpath com.google.gms:google-services:3.0.0 level build..gradle
프로젝트 레벨 build.gradle의 샘플 블록을 참조합니다.
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.3.3'
classpath 'com.google.gms:google-services:3.0.0'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
여기에서 app.gradle 및 project.gradle에 변경 사항을 적용하고 이에 대해 알려줄 수 있습니다, 안녕하세요!
app.gradle의 'com.google.gms.google-services' 응용 프로그램 플러그인은 다음과 같습니다.
apply plugin: 'com.android.application'
android {
compileSdkVersion 24
buildToolsVersion "24.0.2"
defaultConfig {
applicationId "com.example.personal.numbermania"
minSdkVersion 10
targetSdkVersion 24
versionCode 1
versionName "1.0"
multiDexEnabled true
}
dexOptions {
incremental true
javaMaxHeapSize "4g" //Here stablished how many cores you want to use your android studi 4g = 4 cores
}
buildTypes {
debug
{
debuggable true
}
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
testCompile 'junit:junit:4.12'
compile 'com.android.support:appcompat-v7:24.2.1'
compile 'com.android.support:design:24.2.1'
compile 'com.google.firebase:firebase-ads:9.6.1'
compile 'com.google.firebase:firebase-core:9.6.1'
compile 'com.google.android.gms:play-services:9.6.1'
}
apply plugin: 'com.google.gms.google-services'
프로젝트의 그라들에 클래스 경로 추가:
classpath 'com.google.gms:google-services:3.0.0'
SDK Manager의 Google Play Services 라이브러리:
같은 문제가 있었습니다.
이것을 내 의존성에 추가하는 것은 해결되지 않았습니다.
클래스 경로 'com.google.gms:google-services:3.0.0'
나를 위해 해결된 이것을 추가하는 것.
클래스 경로 'com.google.gms:google-services:+'
root build.gradle까지.
단순히 "classpath 'com.google.gms:google-services:3.0.0'"을 Android/build.gradle에 추가하여 다음과 같이 표시합니다.
buildscript {
repositories {
maven {
url "https://maven.google.com"
}
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:3.0.1'
classpath 'com.google.gms:google-services:3.0.0'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
}
또한 Android/app/build.grade의 파일 끝에 "com.google.gms.google-services"를 추가하여 다음과 같이 표시합니다.
apply plugin: 'com.google.gms.google-services'
에 가다Setting > Android SDK > SDK Tools > Google Play Services
Android Studio 4.2.1로 업그레이드할 때 종속성을 설정하라는 메시지가 표시되었습니다.
classpath 'com.google.gms:google-services:4.3.7'
그러나 이로 인해 "ID가 'com.google.gms.google-services'인 플러그인을 찾을 수 없습니다."라는 오류가 발생했습니다.
다음과 같이 유지하면 문제가 해결됩니다.
classpath 'com.google.gms:google-services:4.3.5'
편집:
이 문제는 다음에서 해결되었습니다.
classpath 'com.google.gms:google-services:4.3.8'
build.gradle(모듈:app)에 이 코드를 추가합니다.
dependencies {
……..
compile 'com.google.android.gms:play-services:10.0.1’
……
}
그 후에도 문제가 계속 발생하면 build.gradle(모듈:app)에 이 코드를 추가합니다.
defaultConfig {
….
…...
multiDexEnabled true
}
dependencies {
…..
compile 'com.google.android.gms:play-services:10.0.1'
compile 'com.android.support:multidex:1.0.1'
}
당신에 대해서는 잘 모르겠지만, 여기서 동일한 문제를 해결하는 데 약 30분을 소비했는데, app/build.gradle 행이 다음과 같다는 것을 알게 되었습니다.
apply plugin: 'com.google.gms.google-services'
다음이 아닌 경우:
apply plugin: 'com.google.gms:google-services'
저는 줄을 했지만, 네임스페이스를 할 때이 없습니다.:가 필요합니다가 필요합니다.그것은 사실 점입니다.(.).
이봐... 놓치기 쉽잖아요.
에서 ㅠㅠㅠbuild.gradle해야 합니다.
classpath 'com.google.gms:google-services:$last_version'
그리고 Google Play Service SDK 도구 설치 상태를 확인해주시기 바랍니다.
Firebase를 Flooter 응용 프로그램과 통합하는 동안 이 스레드에 도달했습니다.따라서 Flooth에서 동일한 문제에 직면한 경우 아래 단계에서 문제를 해결했습니다.
고지 사항: 첫 번째 단계는 설명서 및 온라인에서 발견되는 모든 답변/자습서에 설명된 것과 동일합니다.저는 제 대답을 일관되게 하기 위해 그들을 높은 수준에서 언급하고 있을 뿐입니다.
실제 다른 단계로 문제를 해결하는 것이 마지막 단계입니다.
- float_app/android/app 디렉토리에 google-services.json을 추가합니다.
- Android/build.gradle에서 다음을 추가합니다.
repositories { google() jcenter() maven { url "https://maven.google.com" } } dependencies { classpath 'com.android.tools.build:gradle:3.5.0' classpath 'com.google.gms:google-services:4.3.4' classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" } allprojects { repositories { google() jcenter() maven { url "https://maven.google.com" } } }
- Android/app/build.gradle에서 다음을 추가합니다.
apply plugin: 'com.android.application' apply plugin: 'kotlin-android' apply from: "$flutterRoot/packages/flutter_tools/gradle/flutter.gradle" apply plugin: 'com.google.gms.google-services'
- Android/app/build.gradle에서는 다음 항목도 추가합니다.
dependencies { implementation "org.jetbrains.kotlin:kotlin-stdlib-jdk7:$kotlin_version" implementation platform('com.google.firebase:firebase-bom:26.3.0') implementation 'com.google.firebase:firebase-analytics' implementation 'com.google.firebase:firebase-messaging' testImplementation 'junit:junit:4.+' androidTestImplementation 'androidx.test.ext:junit:1.1.2' androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0' }
앱을 실행하기 위해 자신만의 구글-services.json을 추가하고 구글 맵 지리 위치 API에 대한 API KEY를 지정하기만 하면 되는 작업 데모를 https://gitlab.com/ecocupaegean/ecocupaegean/-/tree/master/, 에서 이에 대한 작업 데모를 찾을 수 있습니다.
apply plugin: 'com.google.gms.google-services'
앱 그라들의 맨 아래에 위의 줄을 추가합니다.체격이 좋은
Google 서비스 클래스 경로 버전을 4.2.0에서 3.0.0으로 변경했습니다.
classpath 'com.google.gms:google-services:3.0.0'
그리고 나서 프로젝트를 재구축하고, 이상하게도 프로젝트에 파이어베이스 코어를 추가하자고 제안했습니다.
그리고 앱(모듈)에 파이어베이스 코어를 추가했습니다.
implementation 'com.google.firebase:firebase-messaging:16.0.8'
그리고 나서 그 오류는 마법처럼 사라졌습니다.
위의 답변 중 어떤 것도 제 경우에는 도움이 되지 않았지만, 이 튜토리얼을 따르는 것은 완전히 도움이 되었습니다.Maps SDK for Android / Android Studio 프로젝트 설정
안드로이드 설치 과정에서 구글 문서들이 제게 제대로 작동하지 않았습니다.구글은 문서를 업데이트해야 할 것 같습니다.유일한 해결책은 다음과 같습니다.
- 프로그램에서 에서 Google 수준 Android 응용 Firebase 서서정 Google 서프수 할다수트 Google 도있니습야해가준에추젝로을비인플러그에 추가해야 할 수도 .
build.gradlejava.
dependencies {
classpath 'com.google.gms:google-services:4.3.14'
// ...
}
하면 이플그처수있다니습리를 할 수 .google-services.json응용 프로그램의 코드에 사용할 수 있는 Android 리소스를 파일로 작성하고 생성합니다.또한, 다음 단계가 될 Firebase 관련 라이브러리에 대한 종속성을 설치할 수 있습니다.
- 앱 수준에 이 줄 추가
build.gradle파일:
apply plugin: 'com.google.gms.google-services'
출처:
프로젝트의 build.gradle에서 다음을 추가합니다.
classpath 'com.google.gms:google-services:4.3.3'
안드로이드 범블비에서 이 코드를 build.gradle <프로젝트> 파일의 맨 위에 추가하면 됩니다.
buildscript {
dependencies {
classpath 'com.google.gms:google-services:4.3.10'
}
}
이제 다음과 같이 build.gradle <app.>에 플러그인을 추가해 보십시오.
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'com.google.gms.google-services'
}
언급URL : https://stackoverflow.com/questions/39892622/plugin-with-id-com-google-gms-google-services-not-found
'programing' 카테고리의 다른 글
| msql을 사용하여 업데이트 및 주문하는 방법 (0) | 2023.07.06 |
|---|---|
| std::string length() 및 size() 멤버 함수 (0) | 2023.07.06 |
| NPM 설치 오류:'...nt-webpack-plugin":"0' 근처에서 구문 분석하는 동안 JSON 입력이 예기치 않게 종료되었습니다. (0) | 2023.07.06 |
| jQuery를 사용하여 배열에서 특정 값을 제거하는 방법 (0) | 2023.07.06 |
| web.config 컴파일/assembly 요소는 무엇을 합니까? (0) | 2023.07.06 |

