ios ${EXECUTABLE_NAME} 和 ${PRODUCT_NAME} 在哪里定义
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/8723164/
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
Where are ${EXECUTABLE_NAME} and ${PRODUCT_NAME} defined
提问by Hazel Sophie
Where can I find information on how to modify these
我在哪里可以找到有关如何修改这些的信息
${EXECUTABLE_NAME}
${PRODUCT_NAME}
${EXECUTABLE_NAME}
${PRODUCT_NAME}
These are only displayed in .plist file but where are the actual values.
这些仅显示在 .plist 文件中,但实际值在哪里。
If we can directly modify what ever we want in .plist why we need these.
如果我们可以直接在 .plist 中修改我们想要的内容,为什么我们需要这些。
I am new that's why I'm having problem understanding these, I also looked into apple information Property list key reference but didn't find these ${} values.
我是新手,这就是为什么我在理解这些时遇到问题,我还查看了苹果信息属性列表键引用,但没有找到这些 ${} 值。
回答by Besi
The PRODUCT_NAME
is defined in the target's Build Settings
in the Packaging
section. It has the same name by default as your project.
将PRODUCT_NAME
在目标的定义Build Settings
的Packaging
部分。默认情况下,它与您的项目具有相同的名称。
Edit:
编辑:
While PRODUCT_NAME
is by default the name of the Target (MyDemoApp
in this case). The EXECUTABLE_NAME
is a concatenation of:
PRODUCT_NAME
默认情况下,While是目标的名称(MyDemoApp
在本例中)。这EXECUTABLE_NAME
是一个串联:
$EXECUTABLE_PREFIX
, $PRODUCT_NAME
and $EXECUTABLE_SUFFIX
.
$EXECUTABLE_PREFIX
,$PRODUCT_NAME
和$EXECUTABLE_SUFFIX
。
See the reference of EXECUTABLE_NAMEfor details.
有关详细信息,请参阅EXECUTABLE_NAME的参考。
Update
更新
The new reference can be found here http://help.apple.com/xcode/mac/8.3/#/itcaec37c2a6
新的参考可以在这里找到http://help.apple.com/xcode/mac/8.3/#/itcaec37c2a6
EXECUTABLE_NAME
Specifies the name of the binary the target produces.
EXECUTABLE_NAME
指定目标生成的二进制文件的名称。
回答by utsabiem
I think the $ represents the variable productName & executableName as the $ is used in unix. The variables are set in the build setting of the application. So you should not change the product name directly in the plist file. Instead, go to build settings, search for product name and change it.
我认为 $ 代表变量 productName & executableName 因为 $ 在 unix 中使用。变量在应用程序的构建设置中设置。所以你不应该直接在 plist 文件中更改产品名称。相反,转到构建设置,搜索产品名称并进行更改。