cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
alecb10
Level 3

Have an installer display a version number

I have been given a requirement to have our installer return a version number, something like having the installer executable accept a switch such as -v or an argument of some sort, in which case it just displays the product version number and doesn't install anything.

I couldn't find any way built into IA 2008 Enterprise to do this, and wrote some (trivial) custom code to do it. With an argument like -check.version=true -silent the installer outputs the contents of an IA variable containing a version string to stdout. However this means I have to direct stdout to the console which outputs lots of other stuff.

Can someone suggest an easier/better way to do this? I don't really want stdout directed to the console because I don't want it on during a normal user install. Is there a way to have my custom code do the redirect so that only the value it writes is seen?
Labels (1)
0 Kudos
(2) Replies
pv7721
Level 20

I don't think this is possible with IA. The only workaround that comes to mind is to have the name of the installer contain the version (say instead of having a setup.exe you would have setup-1.5.3-7.exe)
0 Kudos
alecb10
Level 3

Thanks. That was what they were trying to get away from doing, but it looks like they'll just have to bite the bullet. Appreciate your response.
0 Kudos