Old 1st March 2010, 14:45   #1
ssssss
Junior Member
 
Join Date: Mar 2010
Posts: 4
Version number in OutFile

Please! How append my exe-file version to installer output name dynamically? For example: mysoft-setup-2.5.200.exe. Using
code:
!define $VERSION 2.5.200
OutFile mysoft-setup-${VERSION}.exe

is not appropriate method (static).
code:
${GetFileVersion} ${EXE_FULLNAME} $R0
StrCpy $Version $R0

doesn't work too, because executes after OutFile.
ssssss is offline   Reply With Quote
Old 1st March 2010, 15:52   #2
redxii
Senior Member
 
Join Date: Nov 2005
Posts: 115
http://nsis.sourceforge.net/Invoking...n_compile-time
redxii is offline   Reply With Quote
Old 1st March 2010, 17:45   #3
Anders
Moderator
 
Anders's Avatar
 
Join Date: Jun 2002
Location: ${NSISDIR}
Posts: 5,449
!searchparse might also be able to help you out

IntOp $PostCount $PostCount + 1
Anders is offline   Reply With Quote
Old 2nd March 2010, 05:20   #4
MSG
Major Dude
 
Join Date: Oct 2006
Posts: 1,892
And it should be
!define VERSION 2.5.200

not
!define $VERSION 2.5.200

.
MSG is offline   Reply With Quote
Old 4th March 2010, 03:54   #5
ssssss
Junior Member
 
Join Date: Mar 2010
Posts: 4
Thanks to all!! You're right all. Link http://nsis.sourceforge.net/Invoking...n_compile-time is a great solution. How did I miss it?
!searchparse is useful, I think, if version number exists in source code (not my case).
And of course it should be
code:
!define VERSION 2.5.200
It was typing error.
Thanks again!
ssssss is offline   Reply With Quote
Reply
Go Back   Winamp & Shoutcast 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