2017-04-24 10 views
1

なぜ私はすべての解決策について質問していますが、下にプラグインを適用する情報がありますが、これは私の側では機能しません。私は5時間でこれをやろうとします。私のアプリケーションでGoogleマップを実装しようとした後、Imにエラーが発生しました。たぶん私はコードで何かが恋しいですか?私はどこに問題があるのか​​わからないので、コードを見てみてください、おそらくあなたは何が間違っているか考えているでしょう。おかげさまでアドバイス。Google Playサービスは、「更新」して、在庫を「更新」するよう依頼します

これはエラーです:

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. 



apply plugin: 'com.android.application' 

android { 
    compileSdkVersion 25 
    buildToolsVersion "25.0.2" 
    defaultConfig { 
     applicationId "com.company.andrzej.rolki.wroclawnarolkach" 
     minSdkVersion 15 
     targetSdkVersion 25 
     versionCode 1 
     versionName "1.0" 
     testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" 
    } 
    buildTypes { 
     release { 
      minifyEnabled false 
      proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 
     } 
    } 
} 

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' 
    }) 
    configurations.all { 
     resolutionStrategy.force 'com.android.support:support-annotations:22.1.0' 
    } 
    apply plugin: 'com.google.gms.google-services' 
    compile 'com.android.support:appcompat-v7:25.3.1' 
    compile 'com.android.support.constraint:constraint-layout:1.0.2' 
    compile 'com.google.firebase:firebase-ads:10.2.1' 
    compile 'com.jakewharton:butterknife:8.5.1' 
    compile 'com.android.support:support-v4:25.3.1' 
    compile 'com.google.android.gms:play-services-maps:10.2.1' 
    testCompile 'junit:junit:4.12' 
    annotationProcessor 'com.jakewharton:butterknife-compiler:8.5.1' 
    compile 'com.google.firebase:firebase-crash:10.2.1' 
    compile 'com.google.firebase:firebase-core:10.2.1' 
    compile 'com.google.android.gms:play-services-analytics:10.2.1' 
    compile 'com.google.android.gms:play-services-gcm:10.2.1' 
    compile 'com.google.android.gms:play-services-location:10.2.1' 
} 

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

とプロジェクト

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

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

allprojects { 
    repositories { 
     jcenter() 
    } 
} 

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

答えて

1

dependenciesブロックからapply plugin: 'com.google.gms.google-services'行を削除します。あなたはそれを二度書きました。

関連する問題