调试代码签名和配置概要文件部分中缺少的行 [英] Debug rows missing from Code Signing and Provisioning Profile sections

查看:147
本文介绍了调试代码签名和配置概要文件部分中缺少的行的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

问题:

从项目或目标的顶部菜单中选择全部/合并",这就是我所看到的.调试曾经在配置文件配置文件"和代码签名标识"部分中列出,但现在丢失了.我可以像这样在模拟器上构建运行,但是当尝试部署到受限制的测试设备时,出现有关配置概要文件和代码签名的错误.

With All/Combined selected from the top menu within either the Project or the Target, this is what I see. Debug used to be listed within the Provisioning Profile and Code Signing Identity sections, but it is now missing. I can build a run on the simulator like this but when trying to deploy to a tethered testing device I get errors about provisioning profile and code signing being required.

这不是>配置文件"的副本'代码签名'Xcode 6.3 中缺少'选项,因为我选择了All/Combined.不仅仅是Debug在列表中不可见……它甚至不存在于Xcode用于构建列表的project.pbxproj文件中.

This is not a duplicate of 'Provisioning profile' options missing from 'Code signing' Xcode 6.3 because I have All/Combined selected. It's not just that Debug is not visible in the list... it doesn't even exist anymore in the project.pbxproj file that Xcode uses to build the list.

是什么原因造成的:

我试图在Xcode 7.3.1中删除配置文件,并按Delete键,但没有意识到选择了根调试行,而不是选择了保存配置文件本身的子行.我可以将一个子项(例如,任何iOS SDK之类的发行类型)悬停在父行上,然后单击+,将其添加到发行版"或调试"行中,但是我不能像Debug那样添加新的根项.将鼠标悬停在代码签名"或供应配置文件"行上时,没有+号可用.不幸的是,虽然我无法用鼠标删除这些根行之一(它们上没有-按钮),但我还是意外地使用了删除键来删除根行,这就是导致这种损坏状态的原因.

I was trying to remove a profile in Xcode 7.3.1 and pressed the delete key without realizing the root debug row was selected rather than the child row which holds the profile itself. I can add a child (e.g. a release type such as Any iOS SDK) to a Release or Debug row by hovering over the parent row and clicking the +, but I can't add a new root item like Debug that way. No + is available when hovering over the Code Signing or Provisioning Profile rows. Unfortunately, while I can't remove one of these root rows with the mouse (no - button on them), I can accidentally do so with the delete key – which is what led to this broken state.

我尝试过的事情:

清洁,重新启动Xcode和计算机,重新安装Xcode,升级到Xcode 8,迁移到Swift 2.3,迁移到Swift 3,等等.我使用带有JSON语法突出显示的文本编辑器来打开project.pbxproj文件的多个版本(一些在删除之前)以查看差异. project.pbxproj文件用于生成项目和目标的菜单项.旧版本缺少新版本中发行"部分的许多新设置,因为它已经通过Xcode和Swift迁移进行了多次升级迭代.在该文件的其他问题中,我什至都不知道要添加回去的调试"部分中缺少的内容.我可以启动一个新项目,并从project.pbxproj文件的Debug部分中进行复制,但是我坚信手动编辑该文件以尝试重新添加调试项是一个坏主意.可能有更好的选择.

Cleaning, restarting Xcode and computer, reinstalling Xcode, upgrading to Xcode 8, migrating to Swift 2.3, migrating to Swift 3, etc. I used a text editor with JSON syntax highlighting to opened multiple versions of the project.pbxproj file (some before the deletion) to see the differences. The project.pbxproj file is used to generate the menu items for the project and target. The old version is missing many new settings for the Release section found in the new version now that it has gone through several upgrade iterations with Xcode and Swift migrations. Among other concerns with that file, I wouldn't even know what was missing from the Debug section I'd be trying to add back. I could start a fresh project and copy over the Debug section from it's project.pbxproj file, but I'm convinced that manually editing that file to try to add the debug items back is a bad idea. There's probably a better option.

问题:

恢复丢失的调试"菜单项的最佳方法是什么?

推荐答案

我建议的是手动"创建新的Debug配置.您将不会恢复原来的配置,但可以为Debug配置设置正确的配置.

What I would suggest is to create "manually" the new Debug configuration. You will not restore your old configuration but you will be able to set the correct configuration for the Debug configuration.

该操作在在Xcode中添加构建配置中进行了描述,但在您的案例中,您将必须复制Release配置并对其进行编辑以符合您的要求.

The operation is described in Adding a build configuration in Xcode but in your case you will have to duplicate the Release configuration and edit it to fit your requirements.

我还猜想您将必须编辑方案以对每个操作(构建/运行/...)使用正确的配置.

I also guess you will have to edit your schemes to use the correct configuration for each action (build/run/...).

这篇关于调试代码签名和配置概要文件部分中缺少的行的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆