Geeks With Blogs
Zackary Geers blog

I ran across a situation at work where we have some .aspx's that failed to compile, and we didn't have any kind of warning for it in Cruise Control.  I found a great fix for the problem in one of JP's blogs.

That will warn you about errors compiling the aspx file, so you don't have to wait until runtime to find them!  Woohoo!


Here's the script I used for a 3.5 application.  The Tool resolve doesn't work right if the target is 3.5:

Edit: Fixed some bad formatting

<include name="**/*" />



<mkiisdir dirpath="${dir.output}\aspprecompile\" vdirname="aspprecompile" />

<exec program="${framework::get-framework-directory('net-2.0')}\aspnet_compiler.exe">

<arg value="-p" />

<arg value="${dir.output}\aspprecompile" />

<arg value="-v" />

<arg value="aspprecompile" />

<arg value="${dir.output}\appprecompileoutput" />




deliisdir vdirname="aspprecompile" />

<loadtasks assembly="..\tools\nant\NAnt.Contrib.Tasks.dll" />

<delete dir="${dir.output}\appprecompileoutput" if="${directory::exists(dir.output+'\appprecompileoutput')}" />


<fileset basedir="${dir.output}\aspprecompile">

<include name="**\*" />



<copy todir="${dir.output}\aspprecompile">

<fileset basedir="${dir.output}\myapplication">

Posted on Tuesday, January 20, 2009 12:27 PM | Back to top

Comments on this post: Pre-Compiling .aspx files in Cruise Control

No comments posted yet.
Your comment:
 (will show your gravatar)

Copyright © Zackary Geers | Powered by: