Skip to content

iOS Archive does not respect release flag #2999

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
PeterStaev opened this issue Jul 24, 2017 · 2 comments
Open

iOS Archive does not respect release flag #2999

PeterStaev opened this issue Jul 24, 2017 · 2 comments

Comments

@PeterStaev
Copy link
Contributor

I've spent hours debugging a problem with an IPA and ends ups that the CLI does not respect the --release flag when it does archiving. I have the following in my build.xconfig:

DEVELOPMENT_TEAM = 9832T735TV;

CODE_SIGN_ENTITLEMENTS = <My App>/Resources/app.entitlements;
CODE_SIGN_IDENTITY[config=Debug] = iPhone Developer;
CODE_SIGN_IDENTITY[config=Release] = iPhone Distribution;

PROVISIONING_PROFILE[config=Debug] = a5ec2d86-9bfb-48e4-b8c0-a75c39a0a5bd;
PROVISIONING_PROFILE[config=Release] = a03834fd-afb5-4bda-a789-c6bda4550ec0;

ASSETCATALOG_COMPILER_APPICON_NAME = AppIcon;
ASSETCATALOG_COMPILER_LAUNCHIMAGE_NAME = LaunchImage;

When I run tns build ios --for-device --release and I inspect the contents of the platforms/ios/build/device/<myapp>.app the embedded.mobileprovision is the correct one (the Release one above). But if I extract the IPA file's Payload and inspect the embeeded.mobileprovision there it is the wrong one (the Debug one above). If I go to platforms/ios/archive and open the archive in XCode and export for AdHoc (for example) the correct provisioning profile is being used.

Expected behavior
The CLI should use the same provision profile when archiving as the one used to build the .app file.

@ghost
Copy link

ghost commented Jul 24, 2017

Edit: @PeterStaev Confirmed this is what is causing a lot of headache right now, it's trying to select my development certificate when archiving. How do we work around this until a patch is released?

Am not sure if this is related to 3.x, XCode, or something else -- it's happening for someone on ionic too: https://forum.ionicframework.com/t/ionic-prod-release-build-incorrectly-adding-development-provision-profile/98940

@brandonros
Copy link

Was a workaround ever found?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

4 participants