Ionic: 找不到与包名org.apache.cordova(Firebase)相匹配的客户端

8

我是ionic1框架的新手,正在开发sidemenu ionic应用程序。我正在尝试通过使用cordova-plugin-fcm,使Firebase推送通知正常工作。为此,我已经安装了Firebase。

cordova plugin add cordova-plugin-firebase@0.1.19 --save

我需要在我的应用中安装插件。

当我运行 ionic run android 命令时,它提示构建失败错误:

Execution failed for task ':CordovaLib:processDebugGoogleServices'. No matching client found for package name org.apache.cordova

我已经搜索了很多,但没有找到任何解决方案。此外,在我的应用程序配置文件和google-services.json文件中,我有相同的软件包名称。

请帮助我,我真的需要这个。

2个回答

20

我知道这个问题很老套,但如果有人遇到了相同的问题,请检查你在 config.xml 中的 widget id 和在 google-services.json 中的 package_name 是否一致。


0
你需要跟随这个教程,并最终将生成的google-services.json文件添加到你的项目根目录中。

网页内容由stack overflow 提供, 点击上面的
可以查看英文原文,
原文链接