0

我想在我的应用程序中使用火力地堡云端通讯的版本修复版本冲突,我得到这个错误:错误“请要么通过更新谷歌服务的插件

Error:Execution failed for task ':app:processDebugGoogleServices'. 

Please fix the version conflict either by updating the version of the google-services plugin (information about the latest version is available at https://bintray.com/android/android-tools/com.google.gms.google-services/) or updating the version of com.google.android.gms to 9.0.0.

我的项目gradle这个:

buildscript { 
    repositories { 
     jcenter() 
     mavenCentral() 
    } 
    dependencies { 
     classpath 'com.android.tools.build:gradle:2.1.3' 
     classpath 'com.google.gms:google-services:3.0.0' 

    } 
} 

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

task clean(type: Delete) { 
    delete rootProject.buildDir 
} 

我的Gradle模块:

buildscript { 
    repositories { 
     maven { url 'https://maven.fabric.io/public' } 
    } 

    dependencies { 
     classpath 'io.fabric.tools:gradle:1.+' 
    } 
} 
apply plugin: 'com.android.application' 
apply plugin: 'io.fabric' 
apply plugin: 'com.google.gms.google-services' 

repositories { 
    maven { url 'https://maven.fabric.io/public' } 
} 


android { 
    compileSdkVersion 24 
    buildToolsVersion "23.0.3" 

    defaultConfig { 
     applicationId "com.nashkvartal" 
     minSdkVersion 15 
     targetSdkVersion 23 
     versionCode 1 
     versionName "1.0" 
    } 
    buildTypes { 
     release { 
      minifyEnabled false 
      proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 
     } 
    } 

    lintOptions { 
     checkReleaseBuilds false 
     abortOnError false 
    } 
} 

dependencies { 
    compile fileTree(dir: 'libs', include: ['*.jar']) 
    testCompile 'junit:junit:4.12' 
    compile('com.crashlytics.sdk.android:crashlytics:[email protected]') { 
     transitive = true; 
    } 
    compile 'com.android.support:appcompat-v7:24.2.0' 
    compile 'com.android.support:design:24.2.0' 
    compile 'com.android.support:support-v4:24.2.0' 
    compile 'com.loopj.android:android-async-http:1.4.9' 
    compile 'com.google.code.gson:gson:2.6.1' 
    compile 'com.facebook.android:facebook-android-sdk:4.+' 
    compile 'com.vk:androidsdk:+' 
    compile 'com.google.android.gms:play-services-auth:9.4.0' 
    compile 'com.roughike:bottom-bar:1.3.3' 
    compile 'com.google.android.gms:play-services-appindexing:9.4.0' 
    compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.5' 
} 

我该如何解决它的错误?

回答

1

正如错误说,请降级版本9.0.0到模块中的gradle,希望它的工作:

compile 'com.android.support:appcompat-v7:24.2.0' 
compile 'com.android.support:design:24.2.0' 
compile 'com.android.support:support-v4:24.2.0' 
compile 'com.loopj.android:android-async-http:1.4.9' 
compile 'com.google.code.gson:gson:2.6.1' 
compile 'com.facebook.android:facebook-android-sdk:4.+' 
compile 'com.vk:androidsdk:+' 

compile 'com.google.android.gms:play-services-auth:9.0.0'

compile 'com.roughike:bottom-bar:1.3.3' 

compile 'com.google.android.gms:play-services-appindexing:9.0.0'

compile 'com.nostra13.universalimageloader:universal-image-loader:1.9.5' 
相关问题