相关疑难解决方法(0)

95
推荐指数
6
解决办法
10万
查看次数

无法解决:com.google.firebase:firebase-core:11.2.0

在同步我的项目时,我遇到了多个"无法解决"问题.他们都是火力架和游戏服务相关的.我确定它们都是一样的(11.2.0).我也检查过,两者的最新版本是11.2.0.此外,类似问题的所有其他答案都涉及在SDK Manager中更新Google Play服务和存储库,但我的已经是最新的.

在此输入图像描述

在此输入图像描述

知道为什么我无法同步我的项目吗?

编辑 - 当前的工作解决方案

// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        jcenter()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.3.3'
        classpath 'com.google.gms:google-services:3.0.0'
        classpath 'com.google.firebase:firebase-plugins:1.0.4'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }
}

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

task clean(type: Delete) {
    delete rootProject.buildDir
}
Run Code Online (Sandbox Code Playgroud)

android firebase google-play-services android-studio android-gradle-plugin

72
推荐指数
3
解决办法
7万
查看次数

无法解析com.google.android.gms play-services-auth:11.4.0

我想在Android项目中为Android FirebaseUI - Auth编写代码,但是从最近两天开始,我在当前代码中遇到错误,不知道如何修复它.努力但却没有以正确的方式发生.

这是我的build.gradle(项目:FriendlyChat)

// Top-level build file where you can add configuration options common to all sub-projects/modules.

buildscript {
    repositories {
        jcenter()
        mavenLocal()
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:2.2.2'

        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
        classpath 'com.google.gms:google-services:3.0.0'
    }
}

allprojects {
    repositories {
        jcenter()
        mavenLocal()
    }
}

task clean(type: Delete) {
    delete rootProject.buildDir
}
Run Code Online (Sandbox Code Playgroud)

这是我的build.gradle(模块:app)

apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'

repositories {
    mavenLocal()
    flatDir {
        dirs …
Run Code Online (Sandbox Code Playgroud)

java android android-support-library google-play-services android-gradle-plugin

38
推荐指数
6
解决办法
8万
查看次数