Fog Creek Software
Discussion Board




Welcome! and rules

Joel on Software

Command Line Build with .NET

I get all kinds of errors trying to do a command line build.  Mainly I get "project invalid" when it gets to my Web folder.  Has ANYONE successfully built their system with the VS command line tool?

Greg

Greg
Friday, September 10, 2004

yes. buy why? use nant (or maybe msbuild). web projects with visual studio are very single-developer specific, very proper-build-process antagonistic.

mb
Friday, September 10, 2004

We use our own custom build process based on nant, and that builds web applications no problem. Start a Visual Studio command prompt (should be a shortcut for this in the VS.net program group somewhere), then run the command devenv [solution file] /rebuild [debug|release] /out [output report file]

I've bundled all the environment variable setting from the Visual Studio command prompt batch file into my own batch file so I can now run "compileDotNetSolution.bat MySolution.sln release CompileReport.txt" - works a treat.

Mark B
Monday, September 13, 2004

VS.NET needs to access the web site to build a Web project from the command line.  The easiest way to achieve this is to open the VS.NET solution on your build machine and select a url for any web projects it contains.

Subsequently you should be able to build on that machine from the command line without any problem.

Seems a bit ridiculous that you should need to be able to access the website just to build the codebehind DLL.  I believe this will be fixed in VS.NET 2005.

Joe
Monday, September 13, 2004

which is why i use nant--having to set up some random webinfo file on each developer machine, or a build machine which might not even have IIS installed, is asking a bit much.

mb
Tuesday, September 14, 2004

Where I work (and the place before that) we found "web projects" to be less than useless. You can just build regular library DLLs and use them in their place, and they are much easier to work with.

Check this: http://www.pluralsight.com/fritz/Samples/aspdotnet_without_web_projects.htm

Aaron Boodman
Tuesday, September 21, 2004

*  Recent Topics

*  Fog Creek Home