Installation

[This is preliminary documentation and subject to change.]

NAnt is available in either a source or binary distribution. The binary distribution is all you need to use NAnt to build your projects, including creating your own custom tasks, types and functions.

If you are upgrading NAnt from a previous version, you must never install over the top of your previous installation. Delete or rename the existing installation directory before installing the new version of NAnt.

Installing from binaries

  1. Download the binary distribution archive. Either nant-bin.zip or nant-bin.tar.gz will work, the contents of each archive are the same.
  2. Remove any previous versions of NAnt you may have installed.
  3. Extract the contents of the archive to the location you wish to install NAnt (eg: C:\Program Files\NAnt in windows, or /usr/local/nant in Linux)
  4. Depending on your environment, create a wrapper script to run NAnt:

    Run NAnt using Microsoft.NET

    Run NAnt using Mono

  5. Open a new command prompt (shell) and type nant -help. If successful, you should see a usage message displaying available command line options.
  6. (optional) Download and install NAnt-contrib or other third party extensions to NAnt.

Installing from source

  1. Download the source distribution archive. Either nant-src.zip or nant-src.tar.gz will work, the contents of each archive are the same.
  2. Remove any previous versions of NAnt you may have installed.
  3. Extract the contents of the archive to a temporary location. This should not be the location you wish to install NAnt to.
  4. Open a command prompt and change into the folder you extracted the archive to.
  5. Depending on your environment, build the NAnt distribution:

    Install NAnt using Microsoft .NET

    Install NAnt using Mono

    This will first build a bootstrap version of NAnt, and then use that to build and install the full version to installation-path/NAnt.

  6. Follow the instructions as for a binary release from step 5.