I'm building a installer via cli and setting variable using --setvars .

I need to change some Windows Registry entries.

I used: http://support.bitrock.com/files/0000/0017/registryset.xml

as an example.

The issue is - when I run the installer, some variables are not found and registry entries are populated with values like:
***unknown variable version***

Here is part of my project.xml file:

<postInstallationActionList>
        <registrySet>
            <key>HKEY_LOCAL_MACHINE\Software\SoftwareName</key>
            <value>${installdir}</value>
        </registrySet>
        <registrySet>
            <key>HKEY_LOCAL_MACHINE\Software\SoftwareName</key>
            <name>FileVersion</name>
            <value>${version}</value>
        </registrySet>
</postInstallationActionList>

The ${installdir} variable is found, but the ${version} is not.

I tried the suggestions in:
http://answers.bitrock.com/questions/1406/persisting-a-setvars-variable-upon-installation
and
http://answers.bitrock.com/questions/313/how-to-set-variables-at-build-time

I tried to set the variable with the:
stringParameter
and
setInstallerVariable

tags and it did NOT work.

How can I populate Windows Registry entries with variables set from the command line ?

asked 07 Dec '12, 09:50

Neo%20Cortex's gravatar image

Neo Cortex
141242630
accept rate: 0%


Creating the <stringParameter> and using <setInstallerVariable> should work properly. Can you try if using a different variable - such as app_version works properly?

Can you send us your project XML and the command line to build it to support@bitrock.com ? We will then investigate the issue?

link

answered 07 Dec '12, 10:10

wojciechka's gravatar image

wojciechka ♦♦
7.8k61122
accept rate: 26%

A temporary solution (workaround) I use is to create the project.xml file on the fly. This way I substitute the necessary values using PHP (should work with any server side language).

link

answered 13 Dec '12, 06:45

Neo%20Cortex's gravatar image

Neo Cortex
141242630
accept rate: 0%

Your answer
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Tags:

×176
×28
×19
×13
×11
×1

Asked: 07 Dec '12, 09:50

Seen: 2,258 times

Last updated: 13 Dec '12, 06:45