Skip to content
⌘ NSIS Forum Archive

Getting NSIS version

4 posts

tieum#

Getting NSIS version

Hello,

Is there a way to check NSIS compiler version in a script and to error out if the wrong version is installed?

Thanks,

Tieum
tieum#
Thanks for pointing me to the right variable.

The code does not work though as $NSIS_VERSION is valued to v2.29

So I changed it to:

!if `${NSIS_VERSION}` != v2.29
!error `Unsupported NSIS version: ${NSIS_VERSION}. Please use version 2.29`
!endif
Yathosho#
there was just a slight syntax error in afrow's example

!if ${NSIS_VERSION} < v2.29
!error "Unsupported NSIS version: ${NSIS_VERSION}. Please use version v2.29 or later"
!endif

works for me!