<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Wagner Danda Weblog &#187; TFS</title>
	<atom:link href="http://www.wagnerdanda.me/topics/tfs/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.wagnerdanda.me</link>
	<description>.NET, OpenSource, Web 2.0 and other projects</description>
	<lastBuildDate>Fri, 06 Aug 2010 04:28:48 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.1</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>How To Deploy an ASP.NET web application using Team Foundation Server</title>
		<link>http://www.wagnerdanda.me/2009/09/how-to-deploy-an-asp-net-web-application-using-team-foundation-server/</link>
		<comments>http://www.wagnerdanda.me/2009/09/how-to-deploy-an-asp-net-web-application-using-team-foundation-server/#comments</comments>
		<pubDate>Fri, 18 Sep 2009 18:16:51 +0000</pubDate>
		<dc:creator>Wagner Danda</dc:creator>
				<category><![CDATA[.NET]]></category>
		<category><![CDATA[TFS]]></category>
		<category><![CDATA[ASP.NET]]></category>
		<category><![CDATA[Build]]></category>
		<category><![CDATA[ISS]]></category>

		<guid isPermaLink="false">http://www.wagnerdanda.me/?p=9</guid>
		<description><![CDATA[Here is a quick tip on how to modify a TFS build script to publish an ASP.NET site to an existing IIS server (i.e. development environment).
Sample Code
Assuming you have created your basic TFSBuild.proj file, add this to the bottom of the file (right before the &#60;/project&#62; tag):

&#60;!&#8211; This task will be executed after the build [...]]]></description>
			<content:encoded><![CDATA[<p>Here is a quick tip on how to modify a TFS build script to publish an ASP.NET site to an existing IIS server (i.e. development environment).</p>
<p><strong>Sample Code</strong></p>
<p>Assuming you have created your basic TFSBuild.proj file, add this to the bottom of the file (right before the &lt;/project&gt; tag):<br />
<span style="font-size: xx-small;"><em><br />
&lt;!&#8211; This task will be executed after the build is copied to the drop location (i.e. build storage) and<br />
will take care of automating the deployment of the project to an IIS folder<br />
by &#8216;Wagner Danda da Silva&#8217;<br />
&#8211;&gt;<br />
&lt;Target Name=&#8221;AfterDropBuild&#8221; Condition=&#8221; &#8216;$(BuildBreak)&#8217;!=&#8217;true&#8217; &#8220;&gt;</em></span></p>
<p><span style="font-size: xx-small;"><em>&lt;!&#8211; Let&#8217;s prepare the copy by setting the drop location (IIS website folder) ** &#8211;&gt;<br />
&lt;CreateProperty Value=&#8221;<strong><em>\\dswebdev\QA\</em></strong>&#8220;&gt; &lt;!&#8211; replace this with your IIS folder &#8211;&gt;<br />
&lt;Output TaskParameter=&#8221;Value&#8221; PropertyName=&#8221;MyDropLocation&#8221;/&gt;<br />
&lt;/CreateProperty&gt;</p>
<p>&lt;!&#8211; The path below is where the sources can be found after building ASP.NET projects, you probably won&#8217;t need to edit this. &#8211;&gt;<br />
&lt;CreateItem Include=&#8221;$(DropLocation)\$(BuildNumber)\%(ConfigurationToBuild.FlavorToBuild)\_PublishedWebsites\Web\<strong> </strong>\*&#8221;&gt;<br />
&lt;Output TaskParameter=&#8221;Include&#8221; ItemName=&#8221;MyDropFiles&#8221;/&gt;<br />
&lt;/CreateItem&gt;</p>
<p>&lt;!&#8211; Let&#8217;s remove any pre-deployed files. This will delete any existing files inside all folder and subfolders of the drop location. I opted not to use the default TFS delete task because that was removing security permission on my folders and messing up with my build. The command below won&#8217;t do that, will simply delete old files (but it won&#8217;t remove the folders, so if you deleted a folder on your source code you&#8217;ll have to manually remove it from the drop location &#8211; if you actually care for that <img src='http://www.wagnerdanda.me/wp-includes/images/smilies/icon_biggrin.gif' alt=':D' class='wp-smiley' />  &#8211;&gt;<br />
&lt;Exec Command=&#8217;del /f /s /q $(MyDropLocation)\*&#8217;/&gt;</p>
<p>&lt;!&#8211; Copy the files from the build drop location to the IIS website folder &#8211;&gt;<br />
&lt;Exec Command=&#8217;xcopy /Y /R /E &#8220;$(DropLocation)\$(BuildNumber)\%(ConfigurationToBuild.FlavorToBuild)\_PublishedWebsites\Web\<strong>.</strong>&#8221; &#8220;$(MyDropLocation)\<strong>.</strong>&amp;quot;&#8217; /&gt;</p>
<p></em></span></p>
<p><span style="font-size: xx-small;"><em>&lt;/Target&gt;<br />
</em></span></p>
<p>More details can be found here:<a href="http://tfsdeploy2iis.codeplex.com/">http://tfsdeploy2iis.codeplex.com/</a></p>
<p><strong><br />
</strong></p>
]]></content:encoded>
			<wfw:commentRss>http://www.wagnerdanda.me/2009/09/how-to-deploy-an-asp-net-web-application-using-team-foundation-server/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

