Last Published: 2009-03-27  | Version: 0.2.0-M1 | Insight > Release Engineering

Usage

The NSIS Plug-in is designed to participate in the package phase of the build process. Once you configure the plugin, you may execute the plug-in by invoking

mvn package

The individual goals of the package can also be invoked as

mvn nsis:<goal>

Where goal is one of the existing goals of the plug-in.

nsis:clean Goal

Unlike the Maven clean goal, the nsis:clean goal does not clean the entire target directory but just the plug-ins work directory. By default this is ${project.build.directory}/nsis-work

Configuration

This plug-in requires two configurations to run:

pom.xml Configuration

The plugin needs to be defined in the pom.xml with the following required configuration:

<project>
        ...
        <build>
                ...
                <plugins>
                        ...
                        <plugin>
                <groupId>com.mindtree.techworks.insight.releng</groupId>
                <artifactId>maven-nsis-plugin</artifactId>
                <version>0.1.0</version>
                <configuration>
                    <projectFile>/path/to/nsis/project/file</projectFile>
                </configuration>
            </plugin>
            ...
                </plugins>
                ...
        </build>
        ...
</project>

The other optional configurations of this section can be seen in the goal configuration page.

NSIS Install Directory

This plug-in requires NSIS to be installed on the system where the build is being executed. Once NSIS has been installed, there are multiple ways in which the plug-in can get to the makensis.exe file requried.

  • System Path: The directory containing the makensis.exe file can be defined in the system path, and the plug-in can get to it.
  • pom.xml configuration: The plug-in configuration parameter nsisPath can be configured to point to the directory containing the makensis.exe
  • Command line option OR System Variable: The variable nsisPath can be defined at runtime as a system variable or using the maven runtime option as -DnsisPath=/path/to/dir/containing/makensis.exe.

    Please note however that the NSIS Install directory is required only for the compile goal.

NSIS Project configuration

The NSIS project configuration is used for information to generate information and specialization of the installer script for information not available from the pom.xml file of the project.

An annotated configuration of the current version of the project xml is available at NSIS Project Xref.

Maven Repository Configuration

The NSIS plugin is currently not available at the Maven Central repository, hence to get your maven build system to get the plugin, you may use the temporary Insight Maven 2 repository at: