Open newuser44 opened 5 years ago
I don't know why but these lines were missing in the build.gradle file.
// Fabric Cordova Plugin - Start Fabric Build Tools
buildscript {
repositories {
maven { url 'https://maven.fabric.io/public' }
maven { url 'https://maven.google.com' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.25.4'
classpath 'com.google.gms:google-services:+'
}
}
apply plugin: 'io.fabric'
apply plugin: 'com.google.gms.google-services'
Once I added those back things are now building. Not sure why they were missing when removing and adding the platform back.
someone solved it ?
yea @josuper . @newuser44 did it in the response above, adding the code below into the build.gradle
file.
// Fabric Cordova Plugin - Start Fabric Build Tools
buildscript {
repositories {
maven { url 'https://maven.fabric.io/public' }
maven { url 'https://maven.google.com' }
}
dependencies {
classpath 'io.fabric.tools:gradle:1.25.4'
classpath 'com.google.gms:google-services:+'
}
}
apply plugin: 'io.fabric'
apply plugin: 'com.google.gms.google-services'
This does fix it but if you remove android and add it back you have to add this back in. Should it not already be included in the build.gradle when firebase is installed? (I assume that is all that needs those lines?)
Why doesn't this fix it for me?
can you please provide the full code for the build.gradle ?
adding this on android/build.gradle works for me:
maven { url "$rootDir/../node_modules/react-native/android" }
https://rnfirebase.io/docs/v5.x.x/installation/android#Update-Google-Play-service-maven-repository
classpath 'com.google.gms:google-services:4.3.8'
Add this dependency in your Top level build gradle file and you are good to go.
Example:
dependencies { classpath "com.android.tools.build:gradle:4.2.1" classpath 'com.google.gms:google-services:4.3.8' }
Describe the bug We already had plugin working with analytics. Was able to build fine.
I was trying to add android adaptive icons and things would not build. One suggestion was to reinstall the android platform.
After removing android platform (6.3) and adding it back I get a problem doing a build.
I didn't change anything in the config.xml cordova might have. I still have
<resource-file src="google-services.json" target="google-services.json" />
I can see the cordova-plugin-firebase folder with the new-app-build.gradle file This file looks correct
I have tried to uninstall the plugin and add it back (never sure its uninstalled). That didn't seem to change anything.
To Reproduce Setup Ionic with Android 6.3 (or 6.4) Install Firebase Cordova Build code Should work
Expected behavior I expect to be able to build
Plugin Version cordova-plugin-firebase 2.0.2 "Google Firebase Plugin"