从命令行确定 Xcode 派生数据位置
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/13805378/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Determine Xcode derived data location from command line
提问by syvex
Is there a way to determine from the command line what the location of your derived data folder is after building with xcodebuild?
在使用 xcodebuild 构建后,有没有办法从命令行确定派生数据文件夹的位置?
For example, after running xcodebuild:
例如,在运行 xcodebuild 之后:
xcodebuild -project projectname -target targetname
I want to be able to find out which folder the app is in. I would like to do this without changing the output path with CONFIGURATION_BUILD_DIR or within the project settings.
我希望能够找出应用程序所在的文件夹。我希望在不使用 CONFIGURATION_BUILD_DIR 或在项目设置中更改输出路径的情况下执行此操作。
Any ideas?
有任何想法吗?
回答by Martin R
xcodebuild -project myapp.xcodeproj -showBuildSettings
prints all build settings and values, in particular the folder where the app is build:
打印所有构建设置和值,特别是构建应用程序的文件夹:
BUILT_PRODUCTS_DIR = /path/to/myapp/DerivedData/myapp/Build/Products/Release
BUILT_PRODUCTS_DIR = /path/to/myapp/DerivedData/myapp/Build/Products/Release