Search code examples
batch-fileinstallationnsis

NSIS compiler and parameters


How can I set some variables in my nsis script in compile time? for example:

makensis.exe myscript.nsi "buildversion"

I want to set buildversion in my script during compile time. Thanks!


Solution

  • makensis -Dbuildversion=1.2.3.4 myscript.nsi
    

    -D sets a !define, not a variable ( ${adefine}, $avariable ) and you have to get the order of -D and the script correct...