如何在xcode 4中使用一个操作归档多个目标 [英] How do I archive multiple targets with one action in xcode 4

查看:82
本文介绍了如何在xcode 4中使用一个操作归档多个目标的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个包含多个目标的项目,这些目标都适用于不同的iOS应用。例如,Lite版本的一个traget和专业版的另一个traget。

I have a project with multiple targets that are all for different iOS Apps. For instance one traget for the lite version and another one for the pro version.

我想一次构建和归档我的所有应用程序。目前,我有一个针对每个目标的方案,我用它来独立存档每个应用程序。但是现在我必须开始存档,等到它完成然后开始下一个存档。

I want to build and archive all of my Apps at once. Currently I have a scheme for every target which I use to archive each app independently. But now I have to start the archiving, wait until it is done and then start the next one.

有没有办法在xcode 4中使用一个操作或使用命令行归档所有应用程序?

Is there a way to archive all apps with one single action in xcode 4 or using the command line?

推荐答案

计划中的构建操作决定了为哪些操作构建的目标。保留默认值(因此它们都将为Archive操作构建)。当该方案处于活动状态时,当您选择产品 - >存档时,它将在存档之前构建所有请求的目标。

The Build action in a scheme dictates what targets are built for what actions. Leave the defaults (so they'll all be built for the Archive action). When that scheme is active, it'll build all the requested targets just prior to archiving when you select Product -> Archive.

您可以创建一个名为All的新方案,编辑它,然后在其构建操作中,添加要存档的所有目标。然后只需选择该方案并要求它进行存档。

You could create a new scheme called "All", edit it, then in its Build action, add all targets you want to archive. Then just select that scheme and ask it to archive.

或者,将所有目标添加到现有方案中,并取消选中应构建这些额外目标的不需要的操作,只留下存档。

Alternatively, add all targets to your existing scheme and uncheck unwanted actions for which it should build those extra targets, leaving only Archive.

这篇关于如何在xcode 4中使用一个操作归档多个目标的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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