2016-04-04 8 views
2

最終溶液アンドロイド - Googleのサービスプラグインの競合

私は馬鹿です。バージョンアップ後の本当の問題は、ファイルの最後にプラグインを適用していたことです。 Check this topic、私は愚かな質問のためにとても残念、Gradleの仕組みを理解しません


前にひどくオリジナル質問

を探していました。

私は問題に直面しています。何が間違っていて、今何をすべきか分かりません。 私はGCMでアプリを持っており、アプリの第2言語を追加するまでは問題なく機能しました。

次に、google_app_idが翻訳されていないというエラーが表示されます。これは新しいバージョンのGCMパッケージで修正され、新しいバージョンに更新されました。今すぐエラーが発生する

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 8.3.0.

しかし、私は翻訳のエラーのために8.3.0から8.4.0に更新しました。この

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

dependencies { 
    compile fileTree(dir: 'libs', include: ['*.jar']) 
    testCompile 'junit:junit:4.12' 
    compile 'com.android.support:appcompat-v7:23.1.1' 
    compile 'com.android.support:design:23.1.1' 
    compile "com.google.android.gms:play-services-gcm:8.4.0" 
    compile 'com.google.code.gson:gson:2.4' 
    compile 'com.squareup.retrofit:retrofit:2.0.0-beta2' 
    compile 'com.squareup.retrofit:converter-gson:2.0.0-beta2' 
    compile 'com.squareup.picasso:picasso:2.5.2' 
    compile('com.crashlytics.sdk.android:crashlytics:[email protected]') { 
     transitive = true; 
    } 
    compile 'org.apmem.tools:layouts:1.10' 
} 

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

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

はあなたに

答えて

0

lintは、すべての言語でtraslatedされていない文字列を見つけたときにこの種の問題が起こるありがとうございましたように私のbuild.gradleファイルがあります。 2.0.0-alpha3以降は修正する必要があります。

あなたは、いくつかの回避策を使用することができます。

あなたのbuild.gradleファイルにMissingTranslationを無効にすることができます。

buildTypes { 
    release { 
      lintOptions { 
       disable 'MissingTranslation' 
      } 
     } 
} 

すべてのMissingTranslationエラーが無効になるため注意が必要です。

そうでなければあなたとlint.xmlファイルを使用することができます。

<lint> 
    <issue id="MissingTranslation"> 
     <ignore regexp="google_app_id"/> 
    </issue> 
</lint> 
+0

はそれは私が2.0.0-alpha6をしようとした理由です、ありがとう、その後私は別の問題に直面している..私は戻って、使用するダウングレードすべきそれはMissingTranslationエラーを無視するためですか? – Arxeiss

+0

バージョンをダウングレードしません。 alpha6で無視するようにしてください。 –

関連する問題