so I have an app built with Expo but then ejected to get ios and android folder everything works fine on both android and ios I have published it for android but on ios when I try to archive the project it gives me an error Command PhaseScriptExecution failed with nonzero exit code
i don't know what's causing this error I have read a lot of StackOverflow questions tried a lot of things but with no luck here's what I tried so far.
I tried:
pod deintegrate
,
doing pod update
Okay so before, building with Command+B
also didn't work but now i went to Targets->App name->build phases->bundle expo assets-> and checked the " run script only while installing" option and building started working but archiving still doesn't work
along with the above error i also noticed another error on xcode
So please if anyone has any ideas why this is happening, please?
Solution 1:
it is due to Bare Expo Bundle Assets
here is the actual issue raised on forum: https://forums.expo.io/t/ios-bundle-assets-error-when-building-release-403/36616
this pull (fix) request has merged into master
-
update your expo-cli to expo-cli@3.19.2 or higher
npm install -g expo-cli
-
Solution 2:
Open project directory on the terminal and run this command and archive again
react-native bundle --platform ios --dev false --entry-file index.js --bundle-output ./ios/main.jsbundle
Solution 3:
Go to
Keychain Access
-> Right-click on login
-> Lock & unlock again
-> Clean Xcode project
->Make build again