当firebase-auth插件添加时,cordova android构建失败

时间:2018-12-20 15:09:02

标签: android firebase cordova ionic-framework cordova-plugins

自从我将FireBase插件添加到项目中以来,我一直无法构建Android。

我正在与离子一起发展。 并且我们添加了几个插件。

我尝试了cordova-android-play-services-gradle-release插件添加 但不起作用

我尝试在我的项目中找到“ google-play-serivce版本”,并替换15. +,但不起作用!

在我的cordova插件列表中:

cordova-admob-plus 0.0.0 "@admob-plus/cordova"
cordova-android-firebase-gradle-release 2.0.0 "cordova-android-firebase-gradle-release"
cordova-android-play-services-gradle-release 2.0.0 "cordova-android-play-services-gradle-release"
cordova-plugin-app-version 0.1.9 "AppVersion"
cordova-plugin-device 2.0.2 "Device"
cordova-plugin-email-composer 0.8.15 "EmailComposer"
cordova-plugin-facebook4 3.2.0 "Facebook Connect"
cordova-plugin-firebase 2.0.5 "Google Firebase Plugin"
cordova-plugin-firebase-authentication 1.0.1 "cordova-plugin-firebase-authentication"
cordova-plugin-ionic-keyboard 2.1.3 "cordova-plugin-ionic-keyboard"
cordova-plugin-ionic-webview 2.2.5 "cordova-plugin-ionic-webview"
cordova-plugin-splashscreen 5.0.2 "Splashscreen"
cordova-plugin-statusbar 2.4.2 "StatusBar"
cordova-plugin-whitelist 1.3.3 "Whitelist"
cordova-support-android-plugin 1.0.1 "cordova-support-android-plugin"
cordova-support-google-services 1.2.1 "cordova-support-google-services"

当我构建android时,错误消息是:

Configuration 'compile' in project ':app' is deprecated. Use 'implementation' instead.
The Task.leftShift(Closure) method has been deprecated and is scheduled to be removed in Gradle 5.0. Please use Task.doLast(Action) instead.
    at build_5rihf9su8setcaecvlg313jed.run(/Users/dev_pjw/Documents/workspace/bmdevs/tgc-clinet-app/platforms/android/app/build.gradle:152)

FAILURE: Build failed with an exception.

* Where:
Script '/Users/dev_pjw/Documents/workspace/bmdevs/tgc-clinet-app/platforms/android/cordova-support-google-services/tgc-build.gradle' line: 16

* What went wrong:
A problem occurred evaluating project ':app'.
> Failed to apply plugin [class 'com.google.gms.googleservices.GoogleServicesPlugin']
   > Cannot add extension with name 'googleServices', as there is an extension already registered with that name.

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output.

* Get more help at https://help.gradle.org

BUILD FAILED in 2s
/Users/dev_pjw/Documents/workspace/bmdevs/tgc-clinet-app/platforms/android/gradlew: Command failed with exit code 1 Error output:
FAILURE: Build failed with an exception.

我尝试了cordova-android-play-services-gradle-release插件添加 但不起作用

我尝试在我的项目中找到“ google-play-serivce版本”,并替换15. +,但不起作用!

有没有办法添加firebase-auth插件?

0 个答案:

没有答案