dagung
dagung

Reputation: 96

Gradle sync failed: Could not find com.google.gms:google-services:3.0.0

I have problem when implement

classpath 'com.google.gms:google-services:3.0.0'

at build.gradle

this is my Error

Gradle sync failed: Could not find com.google.gms:google-services:3.0.0.
       Searched in the following locations:
       file:/Applications/Android Studio.app/Contents/gradle/m2repository/com/google/gms/google-services/3.0.0/google-services-3.0.0.pom
       file:/Applications/Android Studio.app/Contents/gradle/m2repository/com/google/gms/google-services/3.0.0/google-services-3.0.0.jar
       https://maven.fabric.io/public/com/google/gms/google-services/3.0.0/google-services-3.0.0.pom
       https://maven.fabric.io/public/com/google/gms/google-services/3.0.0/google-services-3.0.0.jar
       http://jzaccone.github.io/SlidingMenu-aar/com/google/gms/google-services/3.0.0/google-services-3.0.0.pom
       http://jzaccone.github.io/SlidingMenu-aar/com/google/gms/google-services/3.0.0/google-services-3.0.0.jar

this is my build.graddle code

buildscript {
dependencies {
    classpath 'io.fabric.tools:gradle:1.+'
    classpath 'com.google.gms:google-services:3.0.0'
}

repositories {
    maven { url 'https://maven.fabric.io/public' }
    maven { url 'http://jzaccone.github.io/SlidingMenu-aar' }
}

}

apply plugin: 'com.android.application'
apply plugin: 'io.fabric'

repositories {
mavenCentral()
jcenter()
maven { url "https://jitpack.io" }
maven { url 'https://maven.fabric.io/public' }
maven { url 'http://jzaccone.github.io/SlidingMenu-aar' }
maven { url "https://oss.sonatype.org/content/repositories/snapshots" }
}

dependencies {
compile fileTree(include: ['*.jar'], dir: 'libs')
compile 'com.google.android.gms:play-services-analytics:9.2.0'
compile 'com.jeremyfeinstein.slidingmenu:library:1.3@aar'
compile('com.crashlytics.sdk.android:crashlytics:2.6.5@aar') { transitive = true; }
}

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

Did you know why this happen. Please help me to fix this? Thanks

Upvotes: 1

Views: 1015

Answers (1)

Ugurcan Yildirim
Ugurcan Yildirim

Reputation: 6132

Check your Android SDK & Tools console in Android Studio and be sure you've installed the latest version of Google Play Services.

Like this: http://image.prntscr.com/image/4c89a169609b47688c1cf05da3b7f515.png

Upvotes: 1

Related Questions