Reputation: 365
I am getting this error while adding "com.google.gms:google-services:3.0.0"
this script in my build.gradle
dependency.
Upvotes: 32
Views: 43176
Reputation: 506
If you are facing problem of connecting firebase to android studio then
goto Tools
-> Firebase
-> Select any option like authenticate using google-sign in
-> then click add the firebase authenticate -> Dependencies will be added automatically.
This helped me.
Upvotes: 4
Reputation: 1258
Apply this in build.gradle(Project: your project name) where tools.build:gradle is present and not in build.gradle(Module: app)
buildscript {
repositories {
jcenter()
}
dependencies {
classpath 'com.android.tools.build:gradle:2.1.2'
classpath 'com.google.gms:google-services:3.0.0'
}
}
In build.gradle(Module: app) outside dependencies add this:
apply plugin: 'com.google.gms.google-services'
Upvotes: 50