Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Should I switch from nant to msbuild?

I currently use nant, ccnet (cruise control), svn, mbunit. I use msbuild to do my sln build just because it was simpler to shell out.

Are there any merits to switching my whole build script to MSBuild? I need to be able to run tests, watir style tests, xcopy deploy. Is this easier?

Update: Any compelling features that would cause me to shift from nant to msbuild?

like image 799
DevelopingChris Avatar asked Aug 14 '08 03:08

DevelopingChris


3 Answers

I like MSBuild. One reason is that .csproj files are msbuild files, and building in VS is just like building at the command line. Another reason is the good support from TeamCity which is the CI server I've been using. If you start using MSBuild, and you want to do more custom things in your build process, get the MSBuild Community Tasks. They give you a bunch of nice extra tasks. I haven't used NAnt for several years now, and I haven't regretted it.

Also, as Ruben mentions, there are the SDC Tasks tasks on CodePlex.

For even more fun, there is the MSBuild Extension Pack on CodePlex, which includes a twitter task.

like image 67
Lance Fisher Avatar answered Sep 23 '22 15:09

Lance Fisher


My advice is just the opposite - Avoid MSBuild like the plague. NANT is far far easier to set up your build to do automatic testing, deploy to multiple production environments, integrate with cruisecontrol for an entry environment, integrate with source control. We've gone through so much pain with TFS/MSBuild (Using TFSDeployer, custom powershell scripts, etc) to get it to do what we were able to do with NANT out of the box. Don't waste your time.

like image 32
Jim Avatar answered Sep 20 '22 15:09

Jim


The most compelling reason to use MSBuild (at least in .NET 3.5 and beyond) - the build engine can build concurrently.

This means a huge speed up in your builds in you have multiple cores/processors.

Previous to 3.5, MSBuild didnt do parallel builds.

like image 39
Adam Avatar answered Sep 21 '22 15:09

Adam