安装firebase脚手架
使用下面命令后能看到自己的项目
firebase login
firebase projects:list
如果是已有的项目套替换注意请修改安卓包名和苹果包名
注意kt引用的包这些都要换成新的
在项目中运行
dart pub global activate flutterfire_cli
flutterfire configure --project=firebase项目名
后面就会自动在firebase中创建项目了
成功后lib文件夹中会生成一个firebase_options文件,如果是换新包名,这个文件的名也会换
报错
还是用的包名,没有替换掉
I/flutter (17440): [core/duplicate-app] A Firebase App named "[DEFAULT]" already exists
gem 没有安装 xcodeproj
Exception: /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require': cannot load such file -- xcodeproj (LoadError)
from /System/Library/Frameworks/Ruby.framework/Versions/2.6/usr/lib/ruby/2.6.0/rubygems/core_ext/kernel_require.rb:54:in `require'
from -e:1:in `<main>'
sudo gem install xcodeproj
谷歌和苹果登录
需要单独去开启