有一种方法。您可以将此类条目添加到您的distribution.xml
<?xml version="1.0" encoding="utf-8" standalone="no"?>
<installer-gui-script minSpecVersion="1">
<title>Application name</title>
<organization>com.organization</organization>
....
<volume-check>
<required-bundles description="Some message which UI Installer doesn't show :(">
<!-- bundle 1 -->
<bundle id="com.organization.app1" path="Applications/App1.app" />
<!-- bundle 2 -->
<bundle id="com.organization.app2" path="Applications/App2.app" />
</required-bundles>
</volume-check>
....
</installer-gui-script>
Run Code Online (Sandbox Code Playgroud)
这在此处记录(required-bundles)。
一些示例可以在 github 上找到。
Apple 安装程序中有一些错误,required-bundles description说:
属性
Run Code Online (Sandbox Code Playgroud)|----------------|------------------|------------------------------------------------------------| | Attribute name | Type | Description | |----------------|------------------|------------------------------------------------------------| | | | _Optional._ Values: `true` (default) to require all of | | `all` | Boolean | the specified bundles, or `false` to require at least one | | | | of them. | |----------------|------------------|------------------------------------------------------------| | `description` | String, | _Optional._ A description of the required bundles, | | | localization key | displayed to the user if the requirement is not met. | |----------------|------------------|------------------------------------------------------------|
因此应该显示来自的消息description,但我在任何地方都看不到它,因此用户可能会困惑为什么他无法安装应用程序。
它只是警告:(You can't install <your application> here, <your application> do not allow it.抱歉,从我的本地化翻译回英语)。
我见过一些安装包正在运行安装检查形式的自定义脚本,使用system.run('script_name').
| 归档时间: |
|
| 查看次数: |
365 次 |
| 最近记录: |