我已经使用firebase作为我的应用程序的后端,因此,我使用firebase auth和firebase UI进行身份验证,但我遇到了错误:
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.android.support', module: 'support-annotations'
})
compile 'com.android.support:appcompat-v7:26.+'
compile 'com.android.support:design:26.+'
compile 'com.android.support:support-vector-drawable:26.+'
compile 'com.android.support.constraint:constraint-layout:1.0.2'
// firebaes dependancies.
compile 'com.firebaseui:firebase-ui-auth:2.1.1'
compile 'com.google.firebase:firebase-core:11.0.2'
compile 'com.google.firebase:firebase-database:11.0.2'
compile 'com.google.firebase:firebase-auth:11.0.2'
testCompile 'junit:junit:4.12'
}
apply plugin: 'com.google.gms.google-services'
我得到的错误是:
Error:Failed to resolve: com.android.support:customtabs:25.4.0
<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile:C:/Users/%USERPROFILE%/AndroidStudioProjects/android-client/app/build.gradle">Open File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
和
Error:Failed to resolve: com.android.support.constraint:constraint-layout:1.1.0-beta1
<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile:C:/Users/%USERPROFILE%/AndroidStudioProjects/android-client/app/build.gradle">Open File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
和
Error:Failed to resolve: com.android.support:cardview-v7:25.4.0
<a href="install.m2.repo">Install Repository and sync project</a><br><a href="openFile:C:/Users/%USERPROFILE%/AndroidStudioProjects/android-client/app/build.gradle">Open File</a><br><a href="open.dependency.in.project.structure">Show in Project Structure dialog</a>
我在这个论坛中找到了类似问题的答案,然后转到SDK Manager&gt; SDK工具&gt; Uppdate存储库。但它没有用!!
任何出现此错误的想法?我猜这是因为Android SDK版本,这是一个正确的猜测吗?
编辑: 我正在使用%USERPROFILE%而不是我的用户文件夹名称。
答案 0 :(得分:0)
不。您正在尝试下载不存在的回购。你从哪里获得了25.4.0
版本?无论如何。如果您要定位牛轧糖,则应将所有25.4.0
替换为25.3.1'
另外,不要使用26.+
。它非常气馁,因为Android Studio本身会告诉你。没有必要做这样的事情。