Well since Paul Stovell sent everyone over to spam me, I thought that I better do as he asks and blog about the RemoveSourceCodeControlBindingTask.     Firstly, I’ll have to correct Paul on what the task is actually doing as he missed out a small, but vital step 🙂 To recap from Pauls post to remove source code control bindings from your project you need to do the following

  1. Delete all vspscc and vssscc files
  2. Remove all lies starting with scc from your solution file
  3. If the project file is a csproj then open up each project and remove the folllowing lines from every project file. This might also work for VBProj files but hasn’t been tested.
    • <SccProjectName>SAK</SccProjectName>
    • <SccLocalPath>SAK</SccLocalPath>
    • <SccAuxPath>SAK</SccAuxPath>
    • <SccProvider>SAK</SccProvider>

So this is what the task does.  Give it a directory and it will search for all *.sln files and *proj files and remove the source code control bindings from it.      Rather than just giving you the code, I have created a setup program that you can get from here that will install the task into the MSBuild directory create a targets file and your can start using it.

Usage:

Add <Import Project=”$(MSBuildExtensionsPath)\Readify\Readify.Useful.MsBuild.Tasks.targets” /> to your msbuild project then at the place you want to call the task add <RemoveSourceCodeControlBindingsTask SourceDirectory=”<DirectoryWhereYourSolutionCanBeFound>” />.

If you have any questions just drop a comment.

Advertisements