Android 添加FirebaseUI依赖项后同步失败
在Android 添加FirebaseUI依赖项后同步失败,android,firebase,firebase-realtime-database,firebase-authentication,firebaseui,Android,Firebase,Firebase Realtime Database,Firebase Authentication,Firebaseui,在build.gradle(应用程序)依赖项中: compile 'com.google.firebase:firebase-database:11.0.4' compile 'com.google.firebase:firebase-auth:11.0.4' 这是导致故障的线路(没有这条线路,它同步时不会出现任何问题) 错误消息: Failed to resolve: com.android.support:customtabs:25.4.0 Failed to resolve: com.a
build.gradle
(应用程序)依赖项中:
compile 'com.google.firebase:firebase-database:11.0.4'
compile 'com.google.firebase:firebase-auth:11.0.4'
这是导致故障的线路(没有这条线路,它同步时不会出现任何问题)
错误消息:
Failed to resolve: com.android.support:customtabs:25.4.0
Failed to resolve: com.android.support.constraint:constraint-layout:1.1.0-beta1
Failed to resolve: com.android.support:design:25.4.0
Failed to resolve: com.android.support:cardview-v7:25.4.0
我建议使用本指南来解决
firebase ui auth
依赖项错误:
其次,为了解决项目中使用com.android.support:
的依赖性错误
转到项目级build.gradle&检查它是否与以下内容完全相同:
allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}
看这个问题/答案:谢谢,现在它可以工作了。我已经多次添加了
maven
,但它不起作用,因为我添加了buildscript
而不是allprojects
#生活
allprojects {
repositories {
jcenter()
maven {
url "https://maven.google.com"
}
}
}