\C{intro} Introduction to NSIS

NSIS is a free scriptable win32 installer/uninstaller system that doesn't suck and isn't huge.

\B{intro-about} About NSIS

NSIS exists largely because of the need to distribute Winamp.

In the beginning, Winamp was distributed as a simple .ZIP file (see Winamp 1.0).
Eventually, Winzip was nice enough to give us a license to the Winzip self extractor (see Winamp 2.0)

The self extracting ZIP file became too restrictive, so we started using a custom developed installer. This installer was generated using a combination of "bin2h", batch files, and Visual C++. To add a new file into the distribution, or to have the installer do something new on install, it required writing quite a bit of code. (see Winamp 2.5)

Another thing we needed was a good way to distribute Winamp plug-ins. The solution: PIMP (Plug-In Mini Packager). PIMP was actually based on the custom installer (though was a lot simpler and removed a lot of code), but stored the data and strings that were unique to that installer in a block at the end of the file. It was small and simple, allowing the simple functions of detecting where Winamp was installed and extracting files. The limitations of PIMP were that it could only extract files, and it was designed for small installers (i.e. an 8mb installer would take 8mb of memory).

NSIS, which stands for "Nullsoft SuperPIMP Installation System" or "Nullsoft Scriptable Installation System" or whatever you want, is based on PIMP but is designed to be much more flexible. NSIS creates installers that are capable of installing, uninstalling, setting system settings, extracting files, etc. Pretty much anything. All with the minimum of overhead- NSIS installers don't bother throwing up a big blue gradient, they don't bother decompressing themselves three different times, telling the user to "please wait". They get to the point and get the job done.

In order to make NSIS even more powerful than it already is, we have released it under an open source license (it is actually the zlib/libpng license, which is approved by opensource.org). What does this mean? It means that if you want to add the functionality you need to NSIS, you can. It means if you want to make your own custom version of NSIS (or some product that includes NSIS), and sell it, you can. Or if you just want to distribute your software using NSIS, you sure as hell can.

The result of all of this is an installation system for win32 that lets you compile nice little scripts (which are text files, no wizards to slow you down) into tiny installers. Many features are supported, and the whole thing just works pretty damn well (at least, we think).

\B{intro-features} Main Features

Here's a short list of some of NSIS' features.

\b SuperPiMP\\&trade; technology (so advanced, so amazing, we won't even tell you what it is).

\b Generates self contained, win32 executable installer.

\b Uninstall support (installer can automagically generate an uninstaller)

\b Optional installer self-verification using a CRC32.

\b Compression choices of zlib or bzip2 based compression. The installer can compress everything together, or individually.

\b Approximately 20-40k overhead over compressed data size (depending on features enabled, compression algorithm, and so on - the default options are ~34k).

\b Ability to display a license agreement, text or RTF

\b Ability to detect destination directory from the registry, and let the user override (or not let them)

\b Customizable appearance (background, icons, text, checkmarks, images)

\b Multiple install configurations (usually Minimal, Typical, Full), and custom configuration

\b Easy to use plug-in system (includes plug-ins for generic dialog construction and user interaction, as well as HTTP downloading)

\b Fully multilingual. 28 translations available including German, French, Spanish, Italian, Dutch, Chinese and more...

\b Installers can be as large as 2GB (theoretically -- when building on Win9x the limit seems to be around 500MB, however building on NT then installing on Win9x works with larger sizes)

\b Optional Silent mode for automated installations

\b A primitive preprocessor

\b User interface changeable from head to toe

\b An optional modern user interface

\b A lovely coding experience with elements of PHP and assembly (includes 20 general purpose variables, a stack, real flow control, etc)

\b Installers have their own VMs that let you write code that can support:

\\<ul\\>

\b File extraction (with configurable overwrite parameters)

\b File/directory copying, renaming, deletion

\b DLL loading (ActiveX control registration/deregistration, extension DLL calling, etc)

\b Executable execution (shell execute and wait options)

\b Shortcut creation

\b Registry key reading/setting/enumerating/deleting

\b INI file reading/writing

\b Generic text file reading/writing

\b Directory scanning

\b Powerful string and integer manipulation

\b Window finding based on class name or title (for is-application-running detection)

\b Window message sending.

\b User interaction with MessageBox.

\b Branching, comparisons, etc.

\b Error checking.

\b Reboot support, including delete or rename on reboot

\b Installer behaviour commands (such as show/hide/wait/etc)

\b User functions in script

\b Callback functions that let you customize the way the installer behaves from script.

\b Macros in script

\\</ul\\>

\b Completely free for any use. See \R{license}{license}.

\b More
