3

build.gradle(APP)的依赖关系:同步失败后FirebaseUI依赖性增加

compile 'com.google.firebase:firebase-database:11.0.4' 
compile 'com.google.firebase:firebase-auth:11.0.4' 

This is the line that causes failure (without this line, it syncs without any problems)

compile 'com.firebaseui:firebase-ui-auth:2.1.1' 

错误消息:

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 
+0

看到这个提问/回答:HTTPS: //stackoverflow.com/q/44691858/4815718 –

回答

3

我建议使用本指南解决firebase-ui-auth相关性错误:Firebase UI Auth

其次,为解决相关性错误,在您的项目com.android.support:

转到项目水平的build.gradle &检查,如果它看起来就像这样:

allprojects { 
    repositories { 
     jcenter() 
     maven { 
      url "https://maven.google.com" 
     } 
    } 
} 
+0

谢谢,现在它工作。我已经多次添加了'maven',但它不起作用,因为我在'allscript'中添加了'buildscript'。 #生活 –