|
This page last changed on May 02, 2007 by rosspatterson.
Most complex build processes use NAnt or MSBuild to script the build. However, for simple projects that just need to build a Visual Studio.NET solution, the Visual Studio task <devenv> provides an easier method.
Examples
Minimalist example:
<devenv>
<solutionfile>src\MyProject.sln</solutionfile>
<configuration>Debug</configuration>
</devenv>
Full example:
<devenv>
<solutionfile>src\MyProject.sln</solutionfile>
<configuration>Debug</configuration>
<buildtype>Build</buildtype>
<project>MyProject</project>
<executable>c:\program files\Microsoft Visual Studio .NET\Common7\IDE\devenv.com</executable>
<buildTimeoutSeconds>600</buildTimeoutSeconds>
</devenv>
Configuration Elements:
| Node |
Description |
Type |
Required |
Default |
| solutionfile |
The path of the solution file to build. If relative, it is relative to the Project Working Directory. |
string |
true |
n/a |
| configuration |
The solution configuration to use (not case sensitive). |
string |
true |
n/a |
| buildtype |
The type of build. Valid values are Rebuild, Build or Clean (not case sensitive). |
string |
false |
rebuild |
| project |
A specific project in the solution, if you only want to build one project (not case sensitive). |
string |
false |
The default is to build all projects selected by the configuration. |
| executable |
The path to devenv.com. |
string |
false |
If not specified, CC.NET will try to find this path from the registry for VS.NET 2003 and 2002 in that order. If you need to use VS.NET 2005, or if you need to use VS.NET 2002 when VS.NET 2003 is installed, you should specify this property to point to the location of devenv.com for the correct VS.NET version. |
| buildTimeoutSeconds |
Number of seconds to wait before assuming that the process has hung and should be killed. |
int |
false |
600 (10 minutes) |
Note: this task requires you to have Visual Studio .NET installed on your integration server.
 | Often programmers like to use a centralised project to build an entire software system. They define specific dependencies and the build order on that specific project to reproduce the behaviours of an nmake build. |
|