简体   繁体   English

iOS - 在 Xcode 中更新配置文件的过程是什么

[英]iOS - What is the procedure for updating a provisioning profile in Xcode

It seems like every time I update my provisioning profile, my xcode project still ends up pointing at the previous profile (I get "Code Sign Error: Provisioning Profile (long string) can't be found.") This means I have to manually do a search and replace on my profile codes in the project as described here: Codesign error: Provisioning profile cannot be found after deleting expired profile似乎每次我更新我的配置文件时,我的 xcode 项目最终仍然指向以前的配置文件(我得到“代码签名错误:找不到配置文件(长字符串)。”)这意味着我必须手动如此处所述,在项目中的我的配置文件代码上进行搜索和替换: 协同设计错误:删除过期配置文件后找不到配置文件

I have to think I'm doing something wrong as this happens every time... what is the procedure for adding in a device to a profile, exporting the profile, and getting my project updated with the new profile?我不得不认为我做错了什么,因为每次都会发生这种情况......将设备添加到配置文件,导出配置文件以及使用新配置文件更新我的项目的过程是什么?

thanks谢谢

In XCode 5 you have to go to Preferences -> Apple ID -> View Details and then press the small refresh button to the bottom left.在 XCode 5 你必须 go 到 Preferences -> Apple ID -> View Details 然后按下左下方的小刷新按钮。 This will update all of your current provisioning profiles.这将更新您当前的所有配置文件。

  1. (optional) Delete old profile in Organizer/Provisioning Profiles(if not used anymore, eg only new device added) (可选)删除管理器/配置配置文件中的旧配置文件(如果不再使用,例如仅添加新设备)
  2. Add New Profile in Organizer/Provisioning Profiles (Drag&Drop)在管理器/供应配置文件中添加新配置文件(拖放)
  3. If you run Xcode 4, be sure to change profiles for project AND targets如果您运行 Xcode 4,请务必更改项目和目标的配置文件

... Sometimes you have to re-open project or even re-start XCode (don't know when or why). ...有时您必须重新打开项目甚至重新启动 XCode(不知道何时或为什么)。

UPDATE:更新:

It turns out, it's better to download the new/changed provisioning profile from developer portal and double click it in Finder.事实证明,最好从开发人员门户下载新的/更改的配置文件并在 Finder 中双击它。 Mac will install it in the right place and you don't have to do the acrobatic stuff in the bottom. Mac 会将它安装在正确的位置,您不必在底部做杂技。

ORIGINAL:原来的:

For Xcode 7.1, you have to do the following:对于 Xcode 7.1,您必须执行以下操作:

  1. Open Preferences > Accounts打开首选项 > 帐户
  2. Remove the dev account in question.删除有问题的开发帐户。
  3. Add the account again.再次添加帐户。
  4. Click "View Details" on the account.单击帐户上的“查看详细信息”
  5. Click "Download All" at the bottom.点击底部的“全部下载”

This will remove all local cache, then fetch the profiles from the server.这将删除所有本地缓存,然后从服务器获取配置文件。

I just had a blast with this when I tried adding a device to a provisioning profile for testing.当我尝试将设备添加到配置文件进行测试时,我对此感到非常兴奋。 Thanks for making it so hard, Apple!感谢苹果,让这一切变得如此艰难!

I just delete the previous provisions from my organizer before adding in the new one with the additional devices just added.我只是从我的组织者中删除了以前的规定,然后再添加刚刚添加的其他设备的新规定。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM