flutterfire_cli icon indicating copy to clipboard operation
flutterfire_cli copied to clipboard

fix: `GoogleService-Info.plist` file not found by Firebase SDK unless added to target

Open russellwheatley opened this issue 2 years ago โ€ข 1 comments

Description

I noticed whilst debugging this issue that initialization was occurring from the dart config file, not the GoogleService-Info.plist file. It appears Firebase will not pick up the file unless it is added to the target.

I also think we should stop writing the config to the DefaultFirebaseOptions class for android & iOS. Unnecessary and, I think, confusing to users.

Type of Change

  • [ ] โœจ feat -- New feature (non-breaking change which adds functionality)
  • [X] ๐Ÿ› ๏ธ fix -- Bug fix (non-breaking change which fixes an issue)
  • [ ] โŒ ! -- Breaking change (fix or feature that would cause existing functionality to change)
  • [ ] ๐Ÿงน refactor -- Code refactor
  • [ ] โœ… ci -- Build configuration change
  • [ ] ๐Ÿ“ docs -- Documentation
  • [ ] ๐Ÿ—‘๏ธ chore -- Chore

russellwheatley avatar Aug 26 '22 12:08 russellwheatley

@Salakar I've updated to abort() ruby script (exit code 1 and writes to stderr), if no "Runner" target exists, then throw exception in CLI to let the user know the issue.

Example: Screenshot 2022-08-26 at 14 39 19

russellwheatley avatar Aug 26 '22 13:08 russellwheatley

I tried to fix this here https://github.com/invertase/flutterfire_cli/pull/88

salahamassi avatar Sep 04 '22 09:09 salahamassi