-
Notifications
You must be signed in to change notification settings - Fork 984
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
feat: support multiple provisioning profiles #956
Conversation
anyone? |
Can you name the issues this PR would close? I see some references but not sure if any of those should be closed with this PR? |
@timbru31 Updated the name, hope this is what you intended. |
@timbru31 done! Thanks for the review. |
@timbru31 anything else that I need to do? Can this be merged? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm to me, but I'm unable to test cause I lack hardware... Would like at least one other PMC member that has a mac to review.
Any one? Can this be merged? I would really like to migrate of my fork and to this repo, hopefully using a npm version, but a git commit will also do as long as I'm not using my getting-out-dated-fork... :-) |
Anything I can do in order to move this request forward? |
I would recommend that you follow up with us on the mailing list or on Slack. |
@brodybits I tried slack and didn't got any response to my post... |
I can confirm that @HarelM solution works, I would appreciate if the pull request it's merged. Also the Current usage in {
"ios": {
"release": {
"codeSignIdentity": "iPhone Distribution",
"developmentTeam": "XXXXXXX",
"packageType": "app-store",
"provisioningProfile": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"iCloudContainerEnvironment": "Production",
"buildFlag": [
"-UseModernBuildSystem=0",
"EMBEDDED_CONTENT_CONTAINS_SWIFT = YES",
"ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES=NO",
"LD_RUNPATH_SEARCH_PATHS = \"@executable_path/Frameworks\""
]
}
}
} Multiple profile usage in {
"ios": {
"release": {
"codeSignIdentity": "iPhone Distribution",
"developmentTeam": "XXXXXXX",
"packageType": "app-store",
"provisioningProfile": {
"app.package.name": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx",
"app.package.name.NotificationService": "xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx"
},
"iCloudContainerEnvironment": "Production",
"buildFlag": [
"-UseModernBuildSystem=0",
"EMBEDDED_CONTENT_CONTAINS_SWIFT = YES",
"ALWAYS_EMBED_SWIFT_STANDARD_LIBRARIES=NO",
"LD_RUNPATH_SEARCH_PATHS = \"@executable_path/Frameworks\""
]
}
}
} |
I'm currently really blocked by this. Does anyone know of a workaround that will allow me to edit the |
You can fork cordova-ios and apply this change if you want the latest version or you can take my fork and use it in |
@HarelM can you confirm that the multiple profile usage of |
I can't confirm this anymore unfortunately. Since this was ignored for far too long I have found a solution that does not use the shareext plugin and thus are not using my fork and do not need two provisioning profiles anymore... Sorry... |
Okay thanks for confirming. Can you share the alternate solution you found please? And on my end yes I've confirmed that the profile has the App Groups feature. |
Yes, I still use them to display images in push notifications First I recommend that you check if the two or more profiles appear in the file Like this: <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
<key>compileBitcode</key>
<false/>
<key>method</key>
<string>app-store</string>
<key>iCloudContainerEnvironment</key>
<string>Production</string>
<key>teamID</key>
<string>XXXXXX</string>
<key>provisioningProfiles</key>
<dict>
<key>app.package.name</key>
<string>xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx</string>
<key>app.package.name.NotificationService</key>
<string>xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx</string>
</dict>
<key>signingStyle</key>
<string>manual</string>
<key>signingCertificate</key>
<string>iPhone Distribution</string>
</dict>
</plist> If the profiles don't appear, open the files |
I basically associate the files and urls with my app, nothing else. |
@ollm thanks for the additional info, I'll check to see if that fixes my problem. @HarelM thanks a lot for sharing. I don't use angular so please confirm if this is a correct description of your workaround: you use the If it is, I have one more question: did you have to take any additional steps to make your app a share target for those file types, or was it sufficient to only specify them in the |
@CodeWithOz in general, yes. |
Can I ask what is preventing merging this and what I can do to assist to move it forward? Would be very useful for my notification service extension allowing me to build via command line, maybe not everyones use case but it works and doesn't impact those not using them. |
BTW, I'm currently migrating to Capacitor where this is not longer a concern as you simply create the |
Could anyone say if there any workaround to use several profiles with cordova build? |
This was my workaround, it didn't got merged, so I don't think there's another option besides building this manually from xcode... |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Code LGTM
Tested the following commands to confirm that the standard process continues to build successfully. (with & without build.json
configurations)
-
cordova build ios
-
cordova build ios --debug
-
cordova build ios --release
-
cordova run ios
(simulator) (ad-hoc)
I also uploaded the built release (ad-hoc) ipa to a physical device running iOS 15.6.1.
As for testing multiple provisioning profiles, I do not have a project to confirm the feature/settings.
Can you rebase against the main branch? The PR has changes to file |
This PR is two years old now. I can't say I fully remember what I did there although the change wasn't big, so in theory I should be able to remember. |
I have send a pull request with the changes on the master branch #1251, I can confirm that these changes work on Could you tell me how can I install |
@ollm any of these variants should work. If you want to install the main branch of your fork, on github.
Note: The path contains Or you can install from a local directory.
|
Thanks, I have tested the changes and it works perfectly with multiple provisioning profiles (I have tested with 2 profiles) If there is anything else I need to do to get the branch merged, please let me know (eg documentation) |
Platforms affected
ios
Motivation and Context
When using a plugin that creates a new target it is currently impossible to sign it using cordova command line.
See issue #953
Resolves #953
Description
Added the option to set multiple provisioning profiles only in the build.json file.
Testing
I've tested this code on the app I'm writing.
Checklist
I added automated test coverage as appropriate for this changeCouldn't understand how... :-((platform)
if this change only applies to one platform (e.g.(android)
)I've updated the documentation if necessarynot sure how to do it since this is only available when using a json file.