<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://blogs.msdn.com/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx</link><description>Yesterday I was complaining to Kieran about how hard it was to debug a custom task. When working on my AssemblyInfo task I was debugging all my regular expressions by running them in a separate command-line app, and with Log.LogMessage() calls in the</description><dc:language>en-US</dc:language><generator>CommunityServer 2.1 SP1 (Build: 61025.2)</generator><item><title>re: How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#599333</link><pubDate>Wed, 17 May 2006 00:38:13 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:599333</guid><dc:creator>otter</dc:creator><description>thank you, this work for me, &amp;nbsp;would be great if this info made it into the documentation, perhaps as a remark on creating a custom task.</description></item><item><title>[MsBuild] Writing and Debugging Custom Tasks</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#1743569</link><pubDate>Fri, 23 Feb 2007 00:26:22 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1743569</guid><dc:creator>Johan Danforth's WebLog</dc:creator><description>&lt;p&gt;Writing a custom task for MSBuild is very simple, here&amp;amp;#39;s the bare minimum code you would need to&lt;/p&gt;
</description></item><item><title>[MsBuild] Writing and Debugging Custom Tasks</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#1745915</link><pubDate>Fri, 23 Feb 2007 11:27:24 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:1745915</guid><dc:creator>Johan's Blog</dc:creator><description>&lt;p&gt;Writing a custom task for MSBuild is very simple, here&amp;amp;#39;s the bare minimum code you would need to&lt;/p&gt;
</description></item><item><title>re: How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#4510641</link><pubDate>Wed, 22 Aug 2007 16:48:57 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:4510641</guid><dc:creator>Jantje</dc:creator><description>&lt;p&gt;This doesn't work, you need to set the working directory instead of &amp;nbsp;the Command line arguments.. &lt;/p&gt;
</description></item><item><title>itworks  &amp;raquo; Blog Archive   &amp;raquo; How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#5962569</link><pubDate>Wed, 07 Nov 2007 18:32:55 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:5962569</guid><dc:creator>itworks  » Blog Archive   » How To: Debug a custom MSBuild task using Visual Studio</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://smccall.ebzzo.com/2007/11/07/how-to-debug-a-custom-msbuild-task-using-visual-studio/"&gt;http://smccall.ebzzo.com/2007/11/07/how-to-debug-a-custom-msbuild-task-using-visual-studio/&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>MSBuild Links</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#8383200</link><pubDate>Sat, 12 Apr 2008 04:01:41 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8383200</guid><dc:creator>Code Junkie</dc:creator><description>&lt;p&gt;For sometime now I have been working on custom MSBuild task. The following links were very useful in&lt;/p&gt;
</description></item><item><title>Microsoft news and tips &amp;raquo; MSBuild Links</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#8385501</link><pubDate>Sat, 12 Apr 2008 19:24:43 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8385501</guid><dc:creator>Microsoft news and tips &amp;raquo; MSBuild Links</dc:creator><description>&lt;p&gt;PingBack from &lt;a rel="nofollow" target="_new" href="http://microsoftnews.askpcdoc.com/?p=1627"&gt;http://microsoftnews.askpcdoc.com/?p=1627&lt;/a&gt;&lt;/p&gt;
</description></item><item><title>re: How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#8733923</link><pubDate>Tue, 15 Jul 2008 19:57:58 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:8733923</guid><dc:creator>Eric Steuart</dc:creator><description>&lt;p&gt;This was very helpful. Jantje's comment about the working directory is partially true. The working directory can make a huge difference in your output, but the command line is also needed so that MSBuild can know what to build. I suggest making the working directory the same as it would be if you were building the project from Visual Studio. This is NOT always the same as the location of the project file.&lt;/p&gt;
</description></item><item><title>re: How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#9393766</link><pubDate>Wed, 04 Feb 2009 00:02:52 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9393766</guid><dc:creator>ratkiley</dc:creator><description>&lt;p&gt;I was not able to get MSBuild 3.5 to work with the above instructions. &amp;nbsp;I think it is because of a change to MSBuild and how it passes parameters in v 3.5. &amp;nbsp;See this link for more info:&lt;/p&gt;
&lt;p&gt;&lt;a rel="nofollow" target="_new" href="http://blogs.msdn.com/aaronhallberg/archive/2007/05/03/tfsbuild-rsp-and-logging-verbosity-in-orcas.aspx"&gt;http://blogs.msdn.com/aaronhallberg/archive/2007/05/03/tfsbuild-rsp-and-logging-verbosity-in-orcas.aspx&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;I was able to get it to work after:&lt;/p&gt;
&lt;p&gt;1) Queue-ing a new build the usual way by right-clicking on the build definition in the Team Explorer in VS 2008.&lt;/p&gt;
&lt;p&gt;2) After the build completes, open up the BuildType\ folder (where the TFSBuild.proj file is located). &amp;nbsp;The BuildType\ folder should be located in the same folder as the Sources\ and Binaries\ folders are located by default. &amp;nbsp;Then, open up the auto-generated TFSBuild.rsp file and copy all of the /p: parameters out of it.&lt;/p&gt;
&lt;p&gt;3) Paste all of the /p: parameters into the command line parameters field in the project field mentioned in the original blog post, followed by the full path to the TFSBuild.proj file (located in the BuildType\ folder).&lt;/p&gt;
&lt;p&gt;4) Set the break point in your custom task, and &amp;quot;Start Debugging&amp;quot; from Visual Studio /(press F5).&lt;/p&gt;
</description></item><item><title>re: How To: Debug a custom MSBuild task using Visual Studio</title><link>http://blogs.msdn.com/msbuild/archive/2005/09/28/474951.aspx#9393770</link><pubDate>Wed, 04 Feb 2009 00:04:30 GMT</pubDate><guid isPermaLink="false">91d46819-8472-40ad-a661-2c78acb4018c:9393770</guid><dc:creator>ratkiley</dc:creator><description>&lt;p&gt;Oh... and the path the the msbuild.exe in the .NET 3.5 framework folder needs to be specified for the command line. &amp;nbsp;It should be something like this:&lt;/p&gt;
&lt;p&gt;C:\WINDOWS\microsoft.net\Framework\v3.5\MSBuild.exe&lt;/p&gt;
</description></item></channel></rss>