I’m facing issues with manual code signing when building a React Native iOS project using the terminal, while it works fine in Xcode GUI.
Setup:
Basic React Native iOS project.Podfile includes use_frameworks! :linkage => :static.
Issue:
Manual Code Signing:Xcode GUI: Successfully archives.Terminal: Fails with provisioning profile errors:
error: DoubleConversion does not support provisioning profiles, butprovisioning profile has been manually specified.
Commands:
Manual Code Signing:
xcodebuild -workspace MyNewProject.xcworkspace -scheme MyNewProject archive -sdk iphoneos -configuration Release -archivePath ./MyNewProject CODE_SIGN_STYLE=Manual CODE_SIGN_IDENTITY='Apple Distribution' PROVISIONING_PROFILE='profile-id'Result: Fails with provisioning profile errors.
Automatic Code Signing:
xcodebuild -workspace MyNewProject.xcworkspace -scheme MyNewProject archive -sdk iphoneos -configuration Release -archivePath ./MyNewProject.xcarchive CODE_SIGN_STYLE=AutomaticResult: Succeeds.
Question:Why does manual code signing fail in the terminal but succeed in Xcode GUI, and how can I fix this?
Any help would be appreciated. Thank you!