There is an ASP.NET Merge Tool (Aspnet_merge.exe) and web deployment projects ( UPDATED: Aspnet_merge.exe comes with Windows SDK components when installing Visual Studio 2008 - see "% Program Files% \ Microsoft SDKs \ Windows \ v6.0A \ bin " ) . These links may be of interest to you:
UPDATED:
In ASP.NET MVC projects, there is the <MvcBuildViews>true/false</MvcBuildViews> , which allows you to compile views in the AfterBuild target environment. But it will not compile your project in one assembly. You must use the ASP.NET merge tool or web deployment projects.
source share