Fuzzybunny
24th January 2007 20:51 UTC
changing the version number via command line
Hi all, I've only looked at this install program for a couple days. I'd like to be able to modify the parameters VIProductVersion and VIAddVersionKey via the command line when we build an install. I've looked through the forums and help files but I haven't found anything yet. Any help would be greatly appreciated.
kichik
24th January 2007 20:55 UTC
You can pass VIProductVersion and VIAddVersionKey on the command line using the /X command line parameter. You could also define a constant using /D and use its value in either of those.
makensis /X"VIProductVersion 1.2.3.4"
makensis /DVERSION=1.2.3.4
# in script
VIProductVersion ${VERSION}
Fuzzybunny
24th January 2007 21:01 UTC
Hi! thanks for the really quick response. :D
When I try that i get an error saying:
"invalid VIProductVersion format, should be X.X.X.X"
Fuzzybunny
24th January 2007 21:04 UTC
sorry just to clarify, in the dos window when i try
makensis /X"VIProductVersion 1.2.3.4"
I get Invalid command: VERSION
when I try
makensis /DVERSION=1.2.3.4
I get invalid VIProductVersion format, shoudl be X.X.X.X
Fuzzybunny
24th January 2007 21:37 UTC
ah i got it, I can't have the script say VIProductVersion $(VERSION). If I comment or remove the line and use:
makensis /X"VIProductVersion X.X.X.X path
that works.
Thanks for the help!
Comm@nder21
25th January 2007 12:33 UTC
you got a typo:
VIProductVersion $(VERSION) is wrong
VIProductVersion ${VERSION} is correct.
with the last one you can use the /D switch.
Fuzzybunny
25th January 2007 15:52 UTC
ahh thats why, silly typo. Thanks!