Reputation: 105
My SDK manager says everything is upto date:
Google Play Services: 33
Google Repository: 35
build.gradle content:
apply plugin: 'com.android.application'
android {
compileSdkVersion 23
buildToolsVersion "23.0.3"
defaultConfig {
applicationId "com.project.cloudmessagingdemo"
minSdkVersion 15
targetSdkVersion 23
versionCode 1
versionName "1.0"
testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
packagingOptions {
exclude 'META-INF/LICENSE'
exclude 'META-INF/LICENSE-FIREBASE.txt'
exclude 'META-INF/notice'
}
}
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'
})
compile 'com.android.support:appcompat-v7:23.4.0'
compile 'com.google.firebase:firebase-messaging:9.2.1'
testCompile 'junit:junit:4.12'
}
Why doesn't this compile?
Upvotes: 0
Views: 3138
Reputation: 357
File name build.gradle(Project:"Your app name")
dependencies {
classpath 'com.android.tools.build:gradle:2.2.0'
classpath 'com.google.gms:google-services:3.0.0'
}
Add that line "classpath 'com.google.gms:google-services:3.0.0' " into build.gradle file in your project
Upvotes: 0
Reputation: 19960
Google Repository 35 contains the latest version - try 'com.google.firebase:firebase-messaging:9.6.1'
.
Unfortunately 9.6.1 was a patch release put out late last week, so not all of the documentation may be updated to point to it quite yet - sorry!
Upvotes: 1