Issue
I am using Firebase with Capacitor. This requires me to have a file named GoogleService-Info.plist
at the root folder of my XCode project. I have that file.
After building and syncing the project with Capacitor, I need to find a way to copy that file to the XCode project.
Simply copying the file using a bash script won't work, as it is then needed to manually add it from the XCode user interface.
I would like to automate this, so that we don't have to manually do that every time we build.
Solution
In capacitor apps you are supposed to commit the ios folder so you only need to manually copy it once, then commit the change so you don’t have to repeat.
But if you want to copy files using node scripts you can use Cordova-node-xcode library, despite the name, it’s not cordova specific https://github.com/apache/cordova-node-xcode
It has an addResourceFile
function that you can use for plist files
Answered By - jcesarmobile
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.