flutter_flavors icon indicating copy to clipboard operation
flutter_flavors copied to clipboard

Multiple commands produce GoogleService-Info.plist

Open rutaba1 opened this issue 3 years ago • 7 comments

Hi! I'm facing this issue when I execute app on iOS

Multiple commands produce '/Users/rutaba/Desktop/fielder_shadman/fielder-mobile-app/build/ios/Debug-dev-iphonesimulator/Fielder.app/GoogleService-Info.plist

Can you help me out on how to solve this one?

rutaba1 avatar Oct 13 '20 17:10 rutaba1

@rutaba1 sucks to be us did you find the solution?

1pavanb avatar Oct 29 '20 12:10 1pavanb

@1pavanb @rutaba1 I am sorry I haven't been able to update this or maintain this as this was for a tutorial. However I have a updated starter project for flutter firebase with Flavors already properly setup and easy to clone and start building your own project with it. Please check https://github.com/lohanidamodar/flutter_firebase_starter

lohanidamodar avatar Oct 29 '20 13:10 lohanidamodar

@lohanidamodar I'm integrating this library into an existing project. No time to reverse engineer that project you show. Thanks for your concern. I figured out the solution.

I'm running a bit late today. I'll try to post the changes for fixing later.

1pavanb avatar Oct 29 '20 13:10 1pavanb

@1pavanb what was the solution?

zanesc avatar Nov 02 '20 06:11 zanesc

after I'm done with the tutorial, I see these two files are added to compile sources by default. Those need to be removed.

image During compilation, it tries to copy both of them into the Runner folder just like it does for AppDelegate.m and GeneratedPluginRestraint.m

So the updated Xcode identifies this behaviour as bad. While looking for the solution some people suggest to choose legacy compiler in the workspace setting to fix this. (I don't like that 😕)

TL;DR Delete both GoogleService-Info.plist from Compiled Sources. Above picture is what it looks like currently.

I'm writing this out of memory, don't know If I'm missing anything. Let me know if it works. @zanesc

1pavanb avatar Nov 02 '20 07:11 1pavanb

@1pavanb awesome info, I believe this is due to recent updates in the Xcode and flutter. It's time I update the tutorial :D

lohanidamodar avatar Nov 02 '20 10:11 lohanidamodar

@1pavanb it worked. thank you

zanesc avatar Nov 05 '20 08:11 zanesc