java - 您在 Izpack 安装的RegistrySpec.xml 中添加了什么来设置 Publisher 字段

标签 java windows installation registry izpack

我正在使用 Izpack 5 构建 Java 应用程序的安装程序。我已使用注册表监听器和其他 dll 正确配置了 install.xml,以便在安装应用程序时,它会列在 Windows 控制面板/程序和功能 下。

但是,发布商大小字段未填写。

我知道我需要创建一个RegistrySpec.xml 文件并在install.xml 中引用它,但是我应该在其中放入什么?

我发现的所有示例都显示了替换卸载包的示例,但这不是我想要做的,我对默认卸载程序很满意,并且不想潜在地破坏该部分,我只想添加发布者和大小字段。

最佳答案

您只需在同一键路径中添加具有相应值的新条目,如下所示:

<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!-- 
    ATTENTION!!! do not edit with an editor which do not handle UTF-8 in a right manner!!
    Storing with a wrong editor can crash this file!
    Registry definition file for IzPack Installation.
    $Id$
-->

<izpack:registry version="5.0"
                 xmlns:izpack="http://izpack.org/schema/registry"
                 xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                 xsi:schemaLocation="http://izpack.org/schema/registry         http://izpack.org/schema/5.0/izpack-registry-5.0.xsd">

    <pack name="UninstallStuff">
        <!-- Special "pack", if not defined an uninstall key will be generated automatically -->
        <!-- The variable $UNINSTALL_NAME can be only used if CheckedHelloPanel will be used
               because there the variable will be declared. With that variabel it is possible
               to install more as one instances of the product on one machine each with an
               unique uninstall key. -->
...
        <value name="Publisher"
            keypath="SOFTWARE\Microsoft\Windows\CurrentVersion\Uninstall\$APP_NAME $APP_VER"
            root="HKLM"
            string="MyCompany Software Inc." />
...
    </pack>
</izpack:registry>

然后您可以对“大小”字段执行相同的操作。

关于java - 您在 Izpack 安装的RegistrySpec.xml 中添加了什么来设置 Publisher 字段,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/17490741/

相关文章:

java - Android中SdCard路径的正确路径?

java - MongoDB Spring session : race condition?

python - 安装 pyenv-win 后本地 python 版本没有改变

python - 如何从源代码构建 Python 3.4.6?

ubuntu - 无法在 Ubuntu 12.04 上安装 NetBeans

directx - DirectX 中的 x64 和 x86 库文件有什么区别?

java - java中分配的内存是否仍保留在下面的代码中

java - GPG 从 Java 解密平面文件

windows - 使用 Certum 证书进行代码签名

python - 为什么我的代码在 windows 上运行良好,但在 ubuntu 上却不行