<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
  <channel xmlns:blog="http://www.dotnetnuke.com/blog/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
    <title>Philip Beadle</title>
    <description>My personal blog on DotNetNuke.</description>
    <link>http://www.dotnetnuke.com/Resources/Blogs/BlogId/20.aspx</link>
    <language>en-US</language>
    <webMaster>philip.beadle@dnncorp.com</webMaster>
    <pubDate>Wed, 23 May 2012 17:15:11 GMT</pubDate>
    <lastBuildDate>Wed, 23 May 2012 17:15:11 GMT</lastBuildDate>
    <docs>http://backend.userland.com/rss</docs>
    <generator>Blog RSS Generator Version 4.0.0.0</generator>
    <item>
      <title>SpecFlow, Watin and DotNetNuke</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3117/SpecFlow-Watin-and-DotNetNuke.aspx</link>
      <description>&lt;p&gt;This is a quick note to let you all know about &lt;a href="http://www.specflow.org"&gt;www.specflow.org&lt;/a&gt; and to get you to check out the video by Steve Sanderson.  I have been investigating using this approach with DNN and have been able to quite easily implement this because we already have hundreds of tests written in the &lt;a href="http://dotnetnukeautomation.codeplex.com/"&gt;automation project&lt;/a&gt;!  All I did was drop the DotNetNuke.Tests.UI.WatiN.Common and DotNetNuke.Tests.UI.WatiN.Utilities projects into the solution and then write the same code that is in existing Automation project tests in the Given, When Then methods.  Worked a treat, now its really easy to use this style of development with DNN.  More soon….&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/3117/SpecFlow-Watin-and-DotNetNuke.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3117/SpecFlow-Watin-and-DotNetNuke.aspx#Comments</comments>
      <slash:comments>6</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/3117/SpecFlow-Watin-and-DotNetNuke.aspx</guid>
      <pubDate>Thu, 14 Jul 2011 00:56:13 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=3117</trackback:ping>
    </item>
    <item>
      <title>My Geek Origins</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3111/My-Geek-Origins.aspx</link>
      <description>&lt;p&gt;Kordsy or delic8genius as he is known is a DPE for Microsoft Australia and he’s &lt;a href="http://delicategeniusblog.com/?p=1292"&gt;collecting Geek origin stories&lt;/a&gt; for some sinister plan at Tech Ed so I thought the best place to write mine up was on my DotNetNuke blog. So where did all this begin for me.&lt;/p&gt;  &lt;p&gt;My earliest recollections about being a geek are back in the ‘80s – yes I’m that old.  My dad worked for Channel 2 TV in Australia and ran a side business of fixing TV’s for people so our shed was always full of open TV’s.  The ones with valves and real wires and knobs and stuff you could work out what it did if your old man showed you.  I was always in the shed soldering things together and helping dad with the various TV’s, radios, VHS players and anything else that plugged in to the wall socket.  Then one day dad came home with a Texas Instruments home computer that we hooked up the biggest TV we had, so I had a PC with a monster 46” screen in 1982!!!  We had a few games like Defender which was a great arcade game at the time which I could now play at home, very cool.  Didn’t take long to figure out we could write our own programs so dad and I wrote some maths programs to teach my sisters maths and then  we found out about sprites and graphics and off I went for quite a few years.&lt;/p&gt;  &lt;p&gt;Teenage years were upon me so computers went out the door for surfing, girls and other distractions.  It wasn't until I finished my Chemical Engineering degree that I got back into programming and while running my own web shop I discovered IBuySpy in 2001.  At the time I was trying to work out if I should jump from VB 6 to .Net, glad i did and I’m extra glad I found DotNetNuke as that has been the focus of my career for the last 9 years.&lt;/p&gt;  &lt;p&gt;Now I get to work on my pet project full time as an Employee of DNN Corp and I love it.  Being a geek rocks!&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/3111/My-Geek-Origins.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3111/My-Geek-Origins.aspx#Comments</comments>
      <slash:comments>3</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/3111/My-Geek-Origins.aspx</guid>
      <pubDate>Fri, 08 Jul 2011 00:09:41 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=3111</trackback:ping>
    </item>
    <item>
      <title>Removing Projects and TFS Binding from Solution Files</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3050/Removing-Projects-and-TFS-Binding-from-Solution-Files.aspx</link>
      <description>&lt;p&gt;At DotNetNuke we distribute many different packages each release including source packages for the Community and our Professional and Enterprise customers.  Internally we have an overarching solution file that contains all of the projects that we work on each day, this solution file also contains all of the unit tests.  When we distribute the source packages we distribute solution files with and without the unit tests as well as a VS2008 formatted sln file and a bunch of variations for Pro and Enterprise customers, that's actually 15 different solution files.  Once the packages are created there is also an automated build that actually compiles each of these packages to ensure we have all the right projects and references set up.&lt;/p&gt;  &lt;p&gt;Also since we are distributing these solutions to users who do not have access to our TFS setup the TFS bindings are also removed.&lt;/p&gt;  &lt;p&gt;All of these various sln files are created from the one solution file so that all of the internal developers only ever have to deal with one sln file.  &lt;/p&gt;  &lt;p&gt;Ok that sets the scene.  The problem is then how to remove the various projects from the solution file such that it will open in Visual Studio and also be buildable from CCNet.  Simply removing the text that defines the project is not sufficient because that leaves the Nested Projects section in a mess.  Even though Visual Studio can open the file MSBuild dies a horrible death thus making it impossible to do automated compiles.&lt;/p&gt;  &lt;p&gt;The custom task i wrote below process the sln files in such a way that both VS and MSBuild can parse the file and do what they need to do.&lt;/p&gt;  &lt;p&gt;To use the task you add the following to your MSBuild file&lt;/p&gt;  &lt;p&gt;&lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;GenerateSolutionFiles&lt;/span&gt; &lt;/p&gt;  &lt;div style="background-color: white; color: black"&gt;   &lt;pre&gt;&lt;span style="color: red"&gt;OriginalFile&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;$(PackagingFolder)\DotNetNuke_Enterprise_UnitTests.sln&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;/pre&gt;

  &lt;pre&gt;&lt;span style="color: red"&gt;CreatedFile&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;$(PackagingFolder)\DotNetNuke_Community_UnitTests_Source.sln&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;/pre&gt;

  &lt;pre&gt;&lt;span style="color: red"&gt;ProjectNames&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;@(AllSolutionsProjects); @(EEProjects); @(PEProjects); &lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt;&lt;span style="color: blue"&gt;@(EETestProjects); DotNetNuke.Professional.HtmlPro&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;/pre&gt;

  &lt;pre&gt;&lt;span style="color: red"&gt;Replacements&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;@(CEReplacements)&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;/pre&gt;

  &lt;pre&gt;&lt;span style="color: red"&gt;RemoveTfsBindings&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;true&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;/&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;You specify the lists of projects to remove in ProjectNames and you can also do simple text replacements where you specify the test to replace and the the replacement text lie so:&lt;/p&gt;

&lt;div style="background-color: white; color: black"&gt;
  &lt;pre&gt;  &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;ItemGroup&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;
    &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;CEReplacements&lt;/span&gt; &lt;span style="color: red"&gt;Include&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;DotNetNuke_Enterprise&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: blue"&gt;/&gt;&lt;/span&gt;
    &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;CEReplacements&lt;/span&gt; &lt;span style="color: red"&gt;Include&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;DotNetNuke_Community&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: blue"&gt;/&gt;&lt;/span&gt;
  &lt;span style="color: blue"&gt;&lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;ItemGroup&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;&lt;/pre&gt;

  &lt;pre&gt; &lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;We use this to manage the website name.&lt;/p&gt;

&lt;p&gt;The code for the Task is below.  enjoy.&lt;/p&gt;

&lt;div style="background-color: white; color: black"&gt;
  &lt;pre&gt;&lt;span style="color: blue"&gt;using&lt;/span&gt; System;
&lt;span style="color: blue"&gt;using&lt;/span&gt; System.Linq;
&lt;span style="color: blue"&gt;using&lt;/span&gt; Microsoft.Build.Utilities;

&lt;span style="color: blue"&gt;namespace&lt;/span&gt; DotNetNuke.MSBuild.Tasks
{
    &lt;span style="color: blue"&gt;using&lt;/span&gt; System.IO;

    &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;class&lt;/span&gt; GenerateSolutionFiles : Task
    {
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; OriginalFile { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; CreatedFile { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt;[] ProjectNames { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt;[] Replacements { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;bool&lt;/span&gt; RemoveTfsBindings { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }

        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;override&lt;/span&gt; &lt;span style="color: blue"&gt;bool&lt;/span&gt; Execute()
        {
            &lt;span style="color: blue"&gt;if&lt;/span&gt; (ProjectNames == &lt;span style="color: blue"&gt;null&lt;/span&gt;)
            {
                &lt;span style="color: blue"&gt;return&lt;/span&gt; &lt;span style="color: blue"&gt;true&lt;/span&gt;;
            }
            &lt;span style="color: blue"&gt;try&lt;/span&gt;
            {
                &lt;span style="color: blue"&gt;var&lt;/span&gt; tr = &lt;span style="color: blue"&gt;new&lt;/span&gt; StreamReader(OriginalFile, &lt;span style="color: blue"&gt;true&lt;/span&gt;);
                tr.Peek();
                &lt;span style="color: blue"&gt;var&lt;/span&gt; fileEncoding = tr.CurrentEncoding;
                &lt;span style="color: blue"&gt;var&lt;/span&gt; content = tr.ReadToEnd();
                tr.Close();
                &lt;span style="color: blue"&gt;var&lt;/span&gt; globalIndex = content.IndexOf(&lt;span style="color: #a31515"&gt;"Global"&lt;/span&gt;);
                &lt;span style="color: blue"&gt;var&lt;/span&gt; globalSection = content.Substring(globalIndex, content.Length - globalIndex);
                &lt;span style="color: blue"&gt;var&lt;/span&gt; globalSections = globalSection.Split(&lt;span style="color: blue"&gt;new&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt;[] { &lt;span style="color: #a31515"&gt;"GlobalSection("&lt;/span&gt; }, &lt;/pre&gt;

  &lt;pre&gt;                  StringSplitOptions.RemoveEmptyEntries);
                &lt;span style="color: blue"&gt;var&lt;/span&gt; projectsSection = content.Substring(0, globalIndex);
                projectsSection = projectsSection.Remove(0, projectsSection.IndexOf(&lt;span style="color: #a31515"&gt;"Project("&lt;/span&gt;));
                &lt;span style="color: blue"&gt;var&lt;/span&gt; projects = projectsSection.Split(&lt;span style="color: blue"&gt;new&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt;[] { &lt;span style="color: #a31515"&gt;"Project("&lt;/span&gt; }, StringSplitOptions.RemoveEmptyEntries);
                &lt;span style="color: blue"&gt;var&lt;/span&gt; nestedProjectsSection = &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty;
                &lt;span style="color: blue"&gt;if&lt;/span&gt; (RemoveTfsBindings)
                {
                    &lt;span style="color: green"&gt;//Remove the TFS section.&lt;/span&gt;
                    content = globalSections.Where(glb =&gt; glb.Contains(&lt;span style="color: #a31515"&gt;"TeamFoundationVersionControl"&lt;/span&gt;)).&lt;/pre&gt;

  &lt;pre&gt;                      Aggregate(content, (current, glb) =&gt; current.Replace(&lt;span style="color: blue"&gt;string&lt;/span&gt;.Concat(&lt;span style="color: #a31515"&gt;"GlobalSection("&lt;/span&gt;, glb), &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty));
                    content = content.Replace(&lt;span style="color: #a31515"&gt;"SAK"&lt;/span&gt;, &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty);
                }
                &lt;span style="color: blue"&gt;foreach&lt;/span&gt; (&lt;span style="color: blue"&gt;var&lt;/span&gt; glb &lt;span style="color: blue"&gt;in&lt;/span&gt; globalSections.Where(glb =&gt; glb.Contains(&lt;span style="color: #a31515"&gt;"NestedProjects"&lt;/span&gt;)))
                {
                    nestedProjectsSection = &lt;span style="color: blue"&gt;string&lt;/span&gt;.Concat(&lt;span style="color: #a31515"&gt;"GlobalSection("&lt;/span&gt;, glb);
                }
                &lt;span style="color: blue"&gt;var&lt;/span&gt; nestedProjects = nestedProjectsSection.Split(&lt;span style="color: blue"&gt;new&lt;/span&gt; &lt;span style="color: blue"&gt;char&lt;/span&gt;[] { &lt;span style="color: #a31515"&gt;'\r'&lt;/span&gt;, &lt;span style="color: #a31515"&gt;'\n'&lt;/span&gt;, &lt;span style="color: #a31515"&gt;'\t'&lt;/span&gt;, &lt;span style="color: #a31515"&gt;'\t'&lt;/span&gt; }, &lt;/pre&gt;

  &lt;pre&gt;                 StringSplitOptions.RemoveEmptyEntries).ToList();
                &lt;span style="color: blue"&gt;foreach&lt;/span&gt; (&lt;span style="color: blue"&gt;var&lt;/span&gt; projectName &lt;span style="color: blue"&gt;in&lt;/span&gt; ProjectNames)
                {
                    &lt;span style="color: blue"&gt;foreach&lt;/span&gt; (&lt;span style="color: blue"&gt;var&lt;/span&gt; project &lt;span style="color: blue"&gt;in&lt;/span&gt; projects)
                    {
                        &lt;span style="color: blue"&gt;if&lt;/span&gt; (project.Contains(&lt;span style="color: #a31515"&gt;"ProjectSection"&lt;/span&gt;)) &lt;span style="color: blue"&gt;continue&lt;/span&gt;;
                        &lt;span style="color: blue"&gt;var&lt;/span&gt; projectEntry = project.Replace(&lt;span style="color: #a31515"&gt;"EndProject"&lt;/span&gt;, &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty).Replace(&lt;span style="color: #a31515"&gt;"\""&lt;/span&gt;, &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty).&lt;/pre&gt;

  &lt;pre&gt;                     Replace(&lt;span style="color: #a31515"&gt;" "&lt;/span&gt;, &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty).Replace(&lt;span style="color: #a31515"&gt;"\r"&lt;/span&gt;, &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty).Replace(&lt;span style="color: #a31515"&gt;"\n"&lt;/span&gt;, &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty);
                        &lt;span style="color: blue"&gt;var&lt;/span&gt; indexFirstEquals = projectEntry.IndexOf(&lt;span style="color: #a31515"&gt;"="&lt;/span&gt;) + 1;
                        projectEntry = projectEntry.Remove(0, indexFirstEquals);
                        &lt;span style="color: blue"&gt;var&lt;/span&gt; projectNameGuid = projectEntry.Split(&lt;span style="color: #a31515"&gt;','&lt;/span&gt;);
                        &lt;span style="color: blue"&gt;if&lt;/span&gt; (projectNameGuid[0] == projectName)
                        {
                            content = content.Replace(&lt;span style="color: blue"&gt;string&lt;/span&gt;.Concat(&lt;span style="color: #a31515"&gt;"Project("&lt;/span&gt;, project), &lt;span style="color: blue"&gt;string&lt;/span&gt;.Empty);
                            &lt;span style="color: blue"&gt;var&lt;/span&gt; nestedProject = nestedProjects.FirstOrDefault(l =&gt; l.StartsWith(projectNameGuid[2]));
                            &lt;span style="color: blue"&gt;if&lt;/span&gt; (nestedProject != &lt;span style="color: blue"&gt;default&lt;/span&gt;(&lt;span style="color: blue"&gt;string&lt;/span&gt;))
                            {
                                nestedProjects.RemoveAll(l =&gt; l.StartsWith(projectNameGuid[2]));
                            }
                        }
                    }
                }
                &lt;span style="color: blue"&gt;var&lt;/span&gt; filteredNestedProjects = &lt;span style="color: blue"&gt;string&lt;/span&gt;.Concat(&lt;span style="color: blue"&gt;string&lt;/span&gt;.Join(&lt;span style="color: #a31515"&gt;"\r\n\t\t"&lt;/span&gt;, nestedProjects.&lt;/pre&gt;

  &lt;pre&gt;                    ToArray()), &lt;span style="color: #a31515"&gt;"\r\n\t"&lt;/span&gt;).Replace(&lt;span style="color: #a31515"&gt;"\tEndGlobalSection"&lt;/span&gt;, &lt;span style="color: #a31515"&gt;"EndGlobalSection"&lt;/span&gt;);
                content = content.Replace(nestedProjectsSection,filteredNestedProjects);

                &lt;span style="color: blue"&gt;if&lt;/span&gt; (Replacements != &lt;span style="color: blue"&gt;null&lt;/span&gt;)
                {
                    &lt;span style="color: blue"&gt;for&lt;/span&gt; (&lt;span style="color: blue"&gt;var&lt;/span&gt; index = 0; index &lt;= Replacements.Length - 1; index = index + 2)
                    {
                        content = content.Replace(Replacements[index], Replacements[index + 1]);
                    }
                }

                &lt;span style="color: blue"&gt;if&lt;/span&gt; (CreatedFile.Contains(&lt;span style="color: #a31515"&gt;"_VS2008"&lt;/span&gt;))
                {
                    &lt;span style="color: green"&gt;//Convert a copy to VS2008&lt;/span&gt;
                    content = content.Replace(&lt;span style="color: #a31515"&gt;"# Visual Studio 2010"&lt;/span&gt;, &lt;span style="color: #a31515"&gt;"# Visual Studio 2008"&lt;/span&gt;);
                    content = content.Replace(&lt;span style="color: #a31515"&gt;"Microsoft Visual Studio Solution File, Format Version 11.00"&lt;/span&gt;, &lt;/pre&gt;

  &lt;pre&gt;                     &lt;span style="color: #a31515"&gt;"Microsoft Visual Studio Solution File, Format Version 10.00"&lt;/span&gt;);
                    content = content.Replace(&lt;span style="color: #a31515"&gt;"vbproj"&lt;/span&gt;, &lt;span style="color: #a31515"&gt;"VS2008.vbproj"&lt;/span&gt;).Replace(&lt;span style="color: #a31515"&gt;"csproj"&lt;/span&gt;, &lt;span style="color: #a31515"&gt;"VS2008.csproj"&lt;/span&gt;);
                }

                &lt;span style="color: blue"&gt;var&lt;/span&gt; newSolutionFile = &lt;span style="color: blue"&gt;new&lt;/span&gt; StreamWriter(CreatedFile, &lt;span style="color: blue"&gt;false&lt;/span&gt;, fileEncoding);
                newSolutionFile.WriteLine(content);
                newSolutionFile.Close();
            }
            &lt;span style="color: blue"&gt;catch&lt;/span&gt; (Exception ex)
            {
                &lt;span style="color: blue"&gt;var&lt;/span&gt; file = &lt;span style="color: blue"&gt;new&lt;/span&gt; StreamWriter(&lt;span style="color: #a31515"&gt;"F:\\Builds\\log.txt"&lt;/span&gt;);
                file.WriteLine(ex.StackTrace);
                file.Close();
                &lt;span style="color: blue"&gt;return&lt;/span&gt; &lt;span style="color: blue"&gt;false&lt;/span&gt;;
            }
            &lt;span style="color: blue"&gt;return&lt;/span&gt; &lt;span style="color: blue"&gt;true&lt;/span&gt;;
        }
    }
}&lt;/pre&gt;
&lt;/div&gt;
&lt;font face="Arial"&gt;&lt;/font&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/3050/Removing-Projects-and-TFS-Binding-from-Solution-Files.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3050/Removing-Projects-and-TFS-Binding-from-Solution-Files.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/3050/Removing-Projects-and-TFS-Binding-from-Solution-Files.aspx</guid>
      <pubDate>Wed, 04 May 2011 20:35:55 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=3050</trackback:ping>
    </item>
    <item>
      <title>MSBuild task to Increment the Build Number</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3049/MSBuild-task-to-Increment-the-Build-Number.aspx</link>
      <description>&lt;p&gt;As part of our internal build process we increment the last number on the build number by one each time the CI build runs.  Sounds simple right but I couldn’t find anywhere that did this simple task so I wrote one myself.  The code below works for VB and C# files and simply takes the AssemblyVersion number out of the provided AssemblyInfo.cs file and increments the last number.  It also provides formatted build numbers, the revision and the new build version as outputs.  You can also specify what you want the version to be, this is useful when you have multiple Assemblyinfo.cs files that you want to keep synchronised as we do with DotNetNuke.&lt;/p&gt;  &lt;p&gt; &lt;/p&gt;  &lt;p&gt;To use the task add this to your MSBuild file&lt;/p&gt;  &lt;div style="background-color: white; color: black"&gt;   &lt;pre&gt;    &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;IncrementBuild&lt;/span&gt; &lt;span style="color: red"&gt;FilePath&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;$(RootFolder)\Library\AssemblyInfo.cs&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: red"&gt;AutoIncrementVersion&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;true&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;
      &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Output&lt;/span&gt; &lt;span style="color: red"&gt;TaskParameter&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;BuildVersion&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: red"&gt;PropertyName&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;BuildVersion&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;&lt;span style="color: blue"&gt;&lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Output&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;
      &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Output&lt;/span&gt; &lt;span style="color: red"&gt;TaskParameter&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;FormattedBuildVersion&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: red"&gt;PropertyName&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;FormattedBuildVersion&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;&lt;span style="color: blue"&gt;&lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Output&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;
      &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;Output&lt;/span&gt; &lt;span style="color: red"&gt;TaskParameter&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;Revision&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: red"&gt;PropertyName&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;Revision&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;&lt;span style="color: blue"&gt;&lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;Output&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;
    &lt;span style="color: blue"&gt;&lt;/&lt;/span&gt;&lt;span style="color: #a31515"&gt;IncrementBuild&lt;/span&gt;&lt;span style="color: blue"&gt;&gt;&lt;/span&gt;
    &lt;span style="color: blue"&gt;&lt;&lt;/span&gt;&lt;span style="color: #a31515"&gt;IncrementBuild&lt;/span&gt; &lt;span style="color: red"&gt;FilePath&lt;/span&gt;&lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;$(RootFolder)\Professional\AssemblyInfo.cs&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt; &lt;span style="color: red"&gt;DefaultVersion&lt;/span&gt; &lt;span style="color: blue"&gt;=&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;$(BuildVersion)&lt;/span&gt;&lt;span style="color: black"&gt;"&lt;/span&gt;&lt;span style="color: blue"&gt;/&gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;font face="Arial"&gt;You can see here that the first use of the task increments the build number and then the second use uses that output to set the version.&lt;/font&gt;

&lt;p&gt; &lt;/p&gt;

&lt;p&gt;The code for the task is below and is getting better exception logging soon.&lt;/p&gt;

&lt;div style="background-color: white; color: black"&gt;
  &lt;pre&gt;&lt;span style="color: blue"&gt;using&lt;/span&gt; System;
&lt;span style="color: blue"&gt;using&lt;/span&gt; System.IO;
&lt;span style="color: blue"&gt;using&lt;/span&gt; Microsoft.Build.Framework;
&lt;span style="color: blue"&gt;using&lt;/span&gt; Microsoft.Build.Utilities;

&lt;span style="color: blue"&gt;namespace&lt;/span&gt; DotNetNuke.MSBuild.Tasks
{
    &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;class&lt;/span&gt; IncrementBuild : Task
    {
        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;const&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; VbVersionStart = &lt;span style="color: #a31515"&gt;"&lt;Assembly: AssemblyVersion"&lt;/span&gt;;
        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;const&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; VbVersionEnd = &lt;span style="color: #a31515"&gt;")&gt;"&lt;/span&gt;;
        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;const&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; CsVersionStart = &lt;span style="color: #a31515"&gt;"[assembly: AssemblyVersion"&lt;/span&gt;;
        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;const&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; CsVersionEnd = &lt;span style="color: #a31515"&gt;")]"&lt;/span&gt;;
        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; _versionStart = CsVersionStart;
        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; _versionEnd = CsVersionEnd;

        &lt;span style="color: blue"&gt;private&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; _filePath;
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; FilePath
        {
            &lt;span style="color: blue"&gt;get&lt;/span&gt;
            {
                &lt;span style="color: blue"&gt;if&lt;/span&gt; (_filePath.EndsWith(&lt;span style="color: #a31515"&gt;"cs"&lt;/span&gt;))
                {
                    _versionStart = CsVersionStart;
                    _versionEnd = CsVersionEnd;
                }
                &lt;span style="color: blue"&gt;else&lt;/span&gt;
                {
                    _versionStart = VbVersionStart;
                    _versionEnd = VbVersionEnd;
                }
                &lt;span style="color: blue"&gt;return&lt;/span&gt; _filePath;
            }
            &lt;span style="color: blue"&gt;set&lt;/span&gt; { _filePath = value; }
        }

        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;bool&lt;/span&gt; AutoIncrementVersion { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }
        [Output]
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; DefaultVersion { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }

        [Output]
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; BuildVersion { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }

        [Output]
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; FormattedBuildVersion { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }

        [Output]
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; Revision { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }

        [Output]
        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;string&lt;/span&gt; ErrorCode { &lt;span style="color: blue"&gt;get&lt;/span&gt;; &lt;span style="color: blue"&gt;set&lt;/span&gt;; }

        &lt;span style="color: blue"&gt;public&lt;/span&gt; &lt;span style="color: blue"&gt;override&lt;/span&gt; &lt;span style="color: blue"&gt;bool&lt;/span&gt; Execute()
        {
            &lt;span style="color: blue"&gt;try&lt;/span&gt;
            {
                &lt;span style="color: blue"&gt;if&lt;/span&gt; (_filePath == &lt;span style="color: blue"&gt;null&lt;/span&gt;)
                {
                    &lt;span style="color: blue"&gt;return&lt;/span&gt; &lt;span style="color: blue"&gt;false&lt;/span&gt;;
                }

                &lt;span style="color: blue"&gt;var&lt;/span&gt; content = File.ReadAllText(FilePath);
                &lt;span style="color: blue"&gt;var&lt;/span&gt; indexStart = content.IndexOf(_versionStart) + 28;
                &lt;span style="color: blue"&gt;var&lt;/span&gt; indexEnd = content.IndexOf(_versionEnd, indexStart);
                &lt;span style="color: blue"&gt;var&lt;/span&gt; versionNumber = content.Substring(indexStart, indexEnd - indexStart - 1);
                &lt;span style="color: blue"&gt;if&lt;/span&gt; (DefaultVersion != &lt;span style="color: blue"&gt;default&lt;/span&gt;(&lt;span style="color: blue"&gt;string&lt;/span&gt;))
                {
                    versionNumber = DefaultVersion;
                }
                &lt;span style="color: blue"&gt;var&lt;/span&gt; values = versionNumber.Split(&lt;span style="color: #a31515"&gt;"."&lt;/span&gt;.ToCharArray());
                ErrorCode = versionNumber;
                &lt;span style="color: blue"&gt;int&lt;/span&gt; main;
                &lt;span style="color: blue"&gt;int&lt;/span&gt; minor;
                &lt;span style="color: blue"&gt;int&lt;/span&gt; version;
                &lt;span style="color: blue"&gt;int&lt;/span&gt; revision;
                &lt;span style="color: blue"&gt;int&lt;/span&gt;.TryParse(values[0], &lt;span style="color: blue"&gt;out&lt;/span&gt; main);
                &lt;span style="color: blue"&gt;int&lt;/span&gt;.TryParse(values[1], &lt;span style="color: blue"&gt;out&lt;/span&gt; minor);
                &lt;span style="color: blue"&gt;int&lt;/span&gt;.TryParse(values[2], &lt;span style="color: blue"&gt;out&lt;/span&gt; version);
                &lt;span style="color: blue"&gt;int&lt;/span&gt;.TryParse(values[3], &lt;span style="color: blue"&gt;out&lt;/span&gt; revision);
                &lt;span style="color: blue"&gt;if&lt;/span&gt; (AutoIncrementVersion)
                {
                    revision = revision + 1;
                }

                BuildVersion = String.Format(&lt;span style="color: #a31515"&gt;"{0}.{1}.{2}.{3}"&lt;/span&gt;, main, minor, version, revision);
                FormattedBuildVersion = String.Format(&lt;span style="color: #a31515"&gt;"{0}.{1}.{2}"&lt;/span&gt;, main.ToString(&lt;span style="color: #a31515"&gt;"00"&lt;/span&gt;), minor.ToString(&lt;span style="color: #a31515"&gt;"00"&lt;/span&gt;), version.ToString(&lt;span style="color: #a31515"&gt;"00"&lt;/span&gt;));
                Revision = revision.ToString();
                &lt;span style="color: blue"&gt;if&lt;/span&gt; (AutoIncrementVersion || DefaultVersion != &lt;span style="color: blue"&gt;default&lt;/span&gt;(&lt;span style="color: blue"&gt;string&lt;/span&gt;))
                {
                    &lt;span style="color: blue"&gt;var&lt;/span&gt; projectFileInfo = &lt;span style="color: blue"&gt;new&lt;/span&gt; FileInfo(FilePath) { IsReadOnly = &lt;span style="color: blue"&gt;false&lt;/span&gt; };
                    content = content.Replace(versionNumber, BuildVersion);
                    &lt;span style="color: blue"&gt;var&lt;/span&gt; newProjectFile = &lt;span style="color: blue"&gt;new&lt;/span&gt; StreamWriter(FilePath);
                    newProjectFile.WriteLine(content);
                    newProjectFile.Close();
                    &lt;span style="color: blue"&gt;var&lt;/span&gt; projectFileInfo2 = &lt;span style="color: blue"&gt;new&lt;/span&gt; FileInfo(FilePath) { IsReadOnly = &lt;span style="color: blue"&gt;true&lt;/span&gt; };
                }

                &lt;span style="color: blue"&gt;return&lt;/span&gt; &lt;span style="color: blue"&gt;true&lt;/span&gt;;

            }
            &lt;span style="color: blue"&gt;catch&lt;/span&gt; (Exception ex)
            {
                &lt;span style="color: blue"&gt;var&lt;/span&gt; file = &lt;span style="color: blue"&gt;new&lt;/span&gt; StreamWriter(&lt;span style="color: #a31515"&gt;"F:\\Builds\\log.txt"&lt;/span&gt;);
                file.WriteLine(ex.StackTrace);
                file.Close();
                &lt;span style="color: blue"&gt;return&lt;/span&gt; &lt;span style="color: blue"&gt;false&lt;/span&gt;;
            }
        }
    }
}&lt;/pre&gt;
&lt;/div&gt;

&lt;p&gt;Enjoy.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/3049/MSBuild-task-to-Increment-the-Build-Number.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/3049/MSBuild-task-to-Increment-the-Build-Number.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/3049/MSBuild-task-to-Increment-the-Build-Number.aspx</guid>
      <pubDate>Wed, 04 May 2011 20:08:48 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=3049</trackback:ping>
    </item>
    <item>
      <title>Adventures with NDepend on the DotNetNuke Codebase&amp;ndash;baseline comparisons</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2991/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-baseline-comparisons.aspx</link>
      <description>&lt;p&gt;One of the first reasons we decided to start using NDepend was to be able to compare the public API from version to version so we could try to stop any breaking changes.  To do this you need to compare a previous build’s NDepend analysis with the current build.  I created a baseline analysis on the released 5.6.1 code base.  I then set my current build’s baseline analysis to the 5.6.1 one and reran the analysis as part of the CI build.&lt;/p&gt;  &lt;p&gt;This of course broke the build!  The build broke because the rules on the API were marked as critical and set to return a false to the build if the rules was broken.  The public API for DNN has some parts of it that even though they are marked as public are not really part of the API, these methods are typically inside the provider pattern and not for external consumption.  I’ll have to figure out how to restrict the analysis to only the real API methods. but that’s a job for later, for now I’m just trying to get the reports showing all of the information we need to start the great refactoring of 2011 &lt;img style="border-bottom-style: none; border-left-style: none; border-top-style: none; border-right-style: none" class="wlEmoticon wlEmoticon-smile" alt="Smile" src="/Portals/25/Blog/Files/20/2991/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_9A7F-wlEmoticon-smile_2.png" /&gt;.&lt;/p&gt;  &lt;p&gt;Here you can see that the analysis is now comparing against the 561EEBaseline&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.dotnetnuke.com/Portals/25/Blog/Files/20/2991/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_9A7F-image_2.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="/Portals/25/Blog/Files/20/2991/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_9A7F-image_thumb.png" width="244" height="127" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;And here you can see the results of clicking the Code Diff tab, the results below show the Public API methods and types that have changed and will need to be investigated to see if they really are public.  &lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.dotnetnuke.com/Portals/25/Blog/Files/20/2991/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_9A7F-image_4.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="/Portals/25/Blog/Files/20/2991/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_9A7F-image_thumb_1.png" width="244" height="160" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;NDepend is providing valuable information about our codebase allowing us to concentrate efforts to improve the codebase.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/2991/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-baseline-comparisons.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2991/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-baseline-comparisons.aspx#Comments</comments>
      <slash:comments>1</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/2991/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-baseline-comparisons.aspx</guid>
      <pubDate>Mon, 07 Mar 2011 00:23:57 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=2991</trackback:ping>
    </item>
    <item>
      <title>Adventures with NDepend on the DotNetNuke Codebase&amp;ndash;Integrating with NCover Community</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2986/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-NCover-Community.aspx</link>
      <description>&lt;p&gt;I was trying to use the free NCover version but I keep getting stuck with this issue that appears to have been fixed in the paid for versions.&lt;/p&gt;  &lt;p&gt;&lt;a title="http://www.ncover.com/forum/show_topic?id=717" href="http://www.ncover.com/forum/show_topic?id=717"&gt;http://www.ncover.com/forum/show_topic?id=717&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;If anyone knows how to get around this issue I’d love to hear.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/2986/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-NCover-Community.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2986/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-NCover-Community.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/2986/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-NCover-Community.aspx</guid>
      <pubDate>Fri, 04 Mar 2011 01:00:41 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=2986</trackback:ping>
    </item>
    <item>
      <title>Adventures with NDepend on the DotNetNuke Codebase&amp;ndash;Integrating with CruiseControl.Net</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2984/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-CruiseControl-Net.aspx</link>
      <description>&lt;p&gt;Next task was to get a NDepend report done for each CI build.  Sounds easy enough and it was once i figured out how to stop breaking the build with NDepend.  We had 3 critical rules breaking that had been marked to break the build.  To get a report out I needed to turn off the breaks.  Once I had that done a nice HTML report is now right in the CruiseControl.Net interface for each build.&lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.dotnetnuke.com/Portals/25/Blog/Files/20/2984/Windows-Live-Writer-7efd80424aab_E0B5-image_2.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="/Portals/25/Blog/Files/20/2984/Windows-Live-Writer-7efd80424aab_E0B5-image_thumb.png" width="244" height="143" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;The next task is to monitor the amount of unit testing done so getting NCover Community Edition going is next.  Once I have that Ill hook it up to NDepend and start to look at the amount of unit test coverage we are getting.  Then we can start to use this information to drive the code quality.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/2984/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-CruiseControl-Net.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2984/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-CruiseControl-Net.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/2984/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Integrating-with-CruiseControl-Net.aspx</guid>
      <pubDate>Thu, 03 Mar 2011 05:08:12 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=2984</trackback:ping>
    </item>
    <item>
      <title>Adventures with NDepend on the DotNetNuke Codebase&amp;ndash;Build mistake found</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2983/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Build-mistake-found.aspx</link>
      <description>&lt;p&gt;Recently Patrick Smacchia from NDepend graciously gave DotNetNuke Corp a pro license of NDepend whic I have been investigating how to use it to achieve some of the engineering teams goals such as reducing cyclometric complexity.  One of the immediate benefits was that NDepend showed that one of the projects was not building correctly according to how we have the build setup.  The UI shows a red alert symbol next to the DotNetNuke.Professional.FileIntegrity.dll indicating that the version of the dll in the bin folder of the website is not the same as the one in the bin folder of the project.  This means that the logic in the .csproj file was not correct where it copies the latest dll from the project to the website bin folder. &lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.dotnetnuke.com/Portals/25/Blog/Files/20/2983/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_D189-image_2.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="/Portals/25/Blog/Files/20/2983/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_D189-image_thumb.png" width="244" height="158" /&gt;&lt;/a&gt;&lt;/p&gt;  &lt;p&gt;So I investigated and found the relative path was one set of “..\” fixed it and &lt;/p&gt;  &lt;p&gt;&lt;a href="http://www.dotnetnuke.com/Portals/25/Blog/Files/20/2983/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_D189-image_4.png"&gt;&lt;img style="background-image: none; border-bottom: 0px; border-left: 0px; margin: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="image" border="0" alt="image" src="/Portals/25/Blog/Files/20/2983/Windows-Live-Writer-Adventures-with-NDepend-on-the-DotNetNuk_D189-image_thumb_1.png" width="244" height="158" /&gt;&lt;/a&gt;&lt;/p&gt;    &lt;p&gt;now the UI shows all greens.  This type of error is normally quite difficult to find and makes debugging difficult as well.  &lt;/p&gt;  &lt;p&gt;I’m liking NDepend a lot so far.  If you have any experience with NDepend and feel like education me please feel free to drop me a line.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/2983/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Build-mistake-found.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2983/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Build-mistake-found.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/2983/Adventures-with-NDepend-on-the-DotNetNuke-Codebase-ndash-Build-mistake-found.aspx</guid>
      <pubDate>Thu, 03 Mar 2011 04:06:20 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=2983</trackback:ping>
    </item>
    <item>
      <title>Powershell script to speed up getting started&amp;ndash;Update</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2967/Powershell-script-to-speed-up-getting-started-ndash-Update.aspx</link>
      <description>&lt;p&gt;I have updated the script a bit (thanx Rob Chartier) so it works more reliably on the read only attribute.&lt;/p&gt;  &lt;p&gt;Here’s the script.&lt;/p&gt;  &lt;p&gt; &lt;/p&gt;  &lt;p&gt;$folder = "C:\DotNetNuke\Team Foundation Server Projects\DotNetNuke\src\Branches\DotNetNuke_5.6.2"   &lt;br /&gt;cd $folder    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;attrib -r *.* /s   &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;$connectionString = "Server=(local);Database=DotNetNuke;Integrated Security=True"   &lt;br /&gt;$webConfigPath = "$folder\website\web.config"    &lt;br /&gt;$xml = [xml](get-content $webConfigPath)    &lt;br /&gt;$root = $xml.get_DocumentElement()    &lt;br /&gt;$root.connectionStrings.add.connectionString = $connectionString    &lt;br /&gt;foreach($n in $xml.selectnodes("/configuration/appSettings/add"))    &lt;br /&gt;    {        &lt;br /&gt;    switch($n.key)        &lt;br /&gt;            {            &lt;br /&gt;            "SiteSqlServer" { $n.value = $connectionString }            &lt;br /&gt;            }    &lt;br /&gt;    }    &lt;br /&gt;$xml.Save($webConfigPath)    &lt;br /&gt;&lt;/p&gt;  &lt;p&gt;Having just written this i reckon Ill some more to it to delete and create the DotNetNuke db as well.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/2967/Powershell-script-to-speed-up-getting-started-ndash-Update.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2967/Powershell-script-to-speed-up-getting-started-ndash-Update.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/2967/Powershell-script-to-speed-up-getting-started-ndash-Update.aspx</guid>
      <pubDate>Mon, 21 Feb 2011 05:25:42 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=2967</trackback:ping>
    </item>
    <item>
      <title>How to trigger Sandcastle from MSBuild</title>
      <link>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2867/How-to-trigger-Sandcastle-from-MSBuild.aspx</link>
      <description>&lt;p&gt;This is a quick note to show you how to build your MSDN style docs using Sandcastle and MSBuild.&lt;/p&gt;  &lt;p&gt;You will need a Sandcastle Help File Builder Project (DotNetNuke_Documentation.shfbproj ) and MSBuild.  Check out the blog post by &lt;a href="http://www.dotnetnuke.com/Community/Blogs/tabid/825/EntryId/1919/Looking-for-MSDN-style-DNN-Core-documentation.aspx" target="_blank"&gt;Ernst Peter Taminga here&lt;/a&gt;.&lt;/p&gt;  &lt;p&gt;Once you have that created you can call MSBuild and build the Sandcastle project with the following line.&lt;/p&gt;  &lt;p&gt;&lt;ShellCommand Command="C:\Windows\Microsoft.NET\Framework\v3.5\MSBuild.exe $(RootFolder)\Tools\MSBuild/DotNetNuke_Documentation.shfbproj /p:Verbose=True" WaitCompletion="True" /&gt;&lt;/p&gt;  &lt;p&gt; &lt;/p&gt;  &lt;p&gt;I call this task from Cruise Control.Net to autoamte the creation of the docs each release now.&lt;/p&gt;&lt;br /&gt;&lt;a href=http://www.dotnetnuke.com/Resources/Blogs/EntryId/2867/How-to-trigger-Sandcastle-from-MSBuild.aspx&gt;More ...&lt;/a&gt;</description>
      <author>philip.beadle@dnncorp.com</author>
      <comments>http://www.dotnetnuke.com/Resources/Blogs/EntryId/2867/How-to-trigger-Sandcastle-from-MSBuild.aspx#Comments</comments>
      <slash:comments>0</slash:comments>
      <guid isPermaLink="true">http://www.dotnetnuke.com/Resources/Blogs/EntryId/2867/How-to-trigger-Sandcastle-from-MSBuild.aspx</guid>
      <pubDate>Wed, 10 Nov 2010 21:23:43 GMT</pubDate>
      <trackback:ping>http://www.dotnetnuke.comDesktopModules/BlogTrackback.aspx?id=2867</trackback:ping>
    </item>
  </channel>
</rss>
