Go Back   Winamp Forums > Developer Center > NSIS Discussion

Reply
Thread Tools Search this Thread Display Modes
Old 24th January 2007, 19:51   #1
Fuzzybunny
Junior Member
 
Join Date: Jan 2007
Posts: 22
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.
Fuzzybunny is offline   Reply With Quote
Old 24th January 2007, 19:55   #2
kichik
M.I.A.
[NSIS Dev, Mod]
 
kichik's Avatar
 
Join Date: Oct 2001
Location: Israel
Posts: 11,338
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.
code:
makensis /X"VIProductVersion 1.2.3.4"

code:
makensis /DVERSION=1.2.3.4
# in script
VIProductVersion ${VERSION}


NSIS FAQ | NSIS Home Page | Donate $
"I hear and I forget. I see and I remember. I do and I understand." -- Confucius
kichik is offline   Reply With Quote
Old 24th January 2007, 20:01   #3
Fuzzybunny
Junior Member
 
Join Date: Jan 2007
Posts: 22
Hi! thanks for the really quick response.
When I try that i get an error saying:
"invalid VIProductVersion format, should be X.X.X.X"
Fuzzybunny is offline   Reply With Quote
Old 24th January 2007, 20:04   #4
Fuzzybunny
Junior Member
 
Join Date: Jan 2007
Posts: 22
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 is offline   Reply With Quote
Old 24th January 2007, 20:37   #5
Fuzzybunny
Junior Member
 
Join Date: Jan 2007
Posts: 22
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!
Fuzzybunny is offline   Reply With Quote
Old 25th January 2007, 11:33   #6
Comm@nder21
Major Dude
 
Join Date: Jul 2003
Location: germany, b-w
Posts: 734
Send a message via ICQ to Comm@nder21
you got a typo:

VIProductVersion $(VERSION) is wrong
VIProductVersion ${VERSION} is correct.

with the last one you can use the /D switch.
Comm@nder21 is offline   Reply With Quote
Old 25th January 2007, 14:52   #7
Fuzzybunny
Junior Member
 
Join Date: Jan 2007
Posts: 22
ahh thats why, silly typo. Thanks!
Fuzzybunny is offline   Reply With Quote
Reply
Go Back   Winamp Forums > Developer Center > NSIS Discussion

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump