To setup nant intellisense in VS 2005 you can copy the schema from the install to the Visual Studio Install\xml\schema directory, however this won’t get all available tasks. As such, I prefer to create a nant file which calls the nantschema task ( This task requires an output attribute be set, which I just set to my Visual Studio Install\xml\schema directory. Below is the build script I use:

<?xml version="1.0" encoding="utf-8"?>
<project name="Build nant schema to VS 2005" default="build" basedir=".">
    <target name="build">
output="C:\Program Files\Microsoft Visual Studio 8\Xml\Schemas\NAnt.xsd"
target-ns="" /> </target> </project>

You can run this after updating Nant or adding contrib projects to your installation and get the latest tasks.

Finally, in your other build files add the xmlns attribute to the project element pointing to the name space you used as the target-ns, in the above example. You may also need to tell VS to open .build files with the xml editor, you can do this by right clicking on the .build file and choosing ‘open with’.