파이어베이스 gradle설정에서 에러가나와요
1231
15 asked
일단 저는 홍학버전을 사용중이구요
강의대로 따라가다가 gradle구성이 제가쓰는 버전이랑 달라서 질문글 찾아보다가 해결방법이있어서 따라서 그대로 진행을 했거든요
그랬더니 이런 에러가나면서 sync가 안되는거예요..
일단 이게 에러 내용이구요
A problem occurred configuring root project 'test'.
> Could not resolve all files for configuration ':classpath'.
> Could not find com.google.gms.google-services:4.3.15:.
Required by:
project :
Possible solution:
- Declare repository providing the artifact, see the documentation at https://docs.gradle.org/current/userguide/declaring_repositories.html
제가 사용한 코드전문을 포함하자면
프로젝트 gradle은
buildscript {
repositories {
google() // Google's Maven repository
mavenCentral() // Maven Central repository
}
dependencies {
classpath 'com.google.gms.google-services:4.3.15'
}
}
plugins {
id 'com.android.application' version '8.0.2' apply false
id 'com.android.library' version '8.0.2' apply false
id 'org.jetbrains.kotlin.android' version '1.8.20' apply false
}이거구요
build gradle은
plugins {
id 'com.android.application'
id 'org.jetbrains.kotlin.android'
id 'com.google.gms.google-services'
}
android {
namespace 'com.example.test'
compileSdk 33
defaultConfig {
applicationId "com.example.test"
minSdk 24
targetSdk 33
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
kotlinOptions {
jvmTarget = '1.8'
}
buildFeatures {
viewBinding true
}
}
dependencies {
implementation 'androidx.core:core-ktx:1.8.0'
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'com.google.android.material:material:1.5.0'
implementation 'androidx.constraintlayout:constraintlayout:2.1.4'
implementation 'com.android.identity:identity-credential:+'
implementation 'com.google.android.gms:play-services-maps:18.1.0'
testImplementation 'junit:junit:4.13.2'
androidTestImplementation 'androidx.test.ext:junit:1.1.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.5.1'
implementation fileTree(include: ['*.jar'], dir: 'libs')
implementation files('libs/libDaumMapAndroid.jar')
implementation platform('com.google.firebase:firebase-bom:32.1.1')
implementation 'com.google.firebase:firebase-analytics-ktx'
}이렇게 구성되어있습니다. 어떤문제가 있는걸까요?
Answer 2
0
아~ 이건 질문글에 올라와있는 글을 보고 해결했습니다!
path대신에 plugin 안에
아래 코드를 넣어서 해결했습니다.
id 'com.google.gms.google-services' version '4.3.10' apply false
주사위앱 소개 및 레이아웃 설정 문제
0
57
2
안드로이드 에뮬레이터가 실행이 안 되요...ㅠ
0
100
2
30 강 소스 좀 올려 주십시요
0
78
2
onBackPressed 함수가 동영상 하고 다르게 동작합니다.
0
88
2
ListView 초기 실행 안됩니다.
0
90
2
코딩을 완료하고난후 앱 실행시 자동 종료
0
68
2
datavinding에서 오류가 납니다.
0
50
1
안드로이드 스튜디오 버전 차이로 초기 empyt activity 선택하면 안됩니다.
0
103
2
context의 구별에 대하여
0
68
2
"프롤로그에서 ..." 오류 관련해 직전 질문에 대한 추가 질문입니다.
0
66
2
"프롤로그에서 콘텐츠가 허용되지 않습니다." 오류
0
152
3
해결완료
1
183
2
databinding 설정후 run하면 에러(해결)
0
221
2
databinding 설정 이후 실행시 에러
0
265
4
안드로이드 입문하는 사람입니다.
0
69
1
Firebase uid
0
74
3
activity_main 화면 다름
0
113
2
강의화면과 다른데 맞게진행되는것인가요...????
0
104
2
파이어베이스 질문
0
71
2
ActivityMainBinding에 오류가 납니다
0
131
2
선생님 onBackPressed 작동이 안되는거 같습니다
0
117
2
>app>res>layout 이 존재하지 않습니다.
0
118
2
안드로이드 스튜디오 미어캣 버전 사용 한글 깨짐
0
744
2
안드로이드 스튜디오 오류 발생 시 대처 방법은 요?
0
284
2

