简体   繁体   English

如何在iOS中的单个项目副本中管理多个项目?

[英]How to manage multiple projects in single project copy in iOS?

现在我们要对所有城市都具有相同的项目,因此我想在一个项目中进行这些项目,因此我可以更改单个项目并在每个项目中都实现。

You need to create one different target for every city, on the same project. 您需要在同一项目中为每个城市创建一个不同的目标。 They will have the same core code and then, you can configure different ressources for all of them. 它们将具有相同的核心代码,然后,您可以为所有这些资源配置不同的资源。 (icons, images, fonts ...) (图标,图像,字体...)

Each of them can use a different plist file in order to have some flags and not others. 他们每个人都可以使用不同的plist文件以具有一些标志,而没有其他标志。

To create a new target : * Go to your project panel (with tabs General - Capabilities - Resources tag ...) * Open the left panel * There is a + at the bottom to create your new target (or you can copy an existing one) 要创建新目标,请执行以下操作:*转到项目面板(带有“常规”-“功能”-“资源”标签选项卡...)*打开左面板。*底部有一个+,用于创建新目标(或者您可以复制现有目标一)

You can switch from a target to another on the top bar at the right of the selected device to debug 您可以在所选设备右侧的顶部栏中从目标切换到另一个以进行调试

When you have a file, you can decide on which target he can go on the right panel on the section "Target Membership" 拥有文件后,您可以在“目标成员身份”部分的右侧面板上确定他可以进入哪个目标

Need screenshots ? 需要截图吗?

Very nice explained with pictures is here . 图片很好的解释在这里 You can achieve it by using targets in Xcode. 您可以通过使用Xcode中的目标来实现。

As well here is explained about targets. 此处还介绍了有关目标的信息。

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

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