Wednesday, July 30, 2008

AfterBuild copy task

Have you ever had to get a licence (.lic) file copied to your bin directory as part of you build?

Well annoyingly enough you don't want it to be marked as "Content" and you cant compile it, so I placed the following line into my .csproj file quite near the bottom. I have included the targets above so you can see where I placed it in bold.

<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
<PropertyGroup>
<PreBuildEvent>
</PreBuildEvent>
<PostBuildEvent>
</PostBuildEvent>
</PropertyGroup>
<Target Name="AfterBuild">
<CreateItem Include="$(ProjectDir)ThirdPartyLibraries\PowerUp.Web.UI.WebTree.lic">
<Output TaskParameter="Include" ItemName="LicenceFile" />
</CreateItem>
<Copy SourceFiles="@(LicenceFile)" DestinationFolder="$(OutputPath)" ContinueOnError="false" />
</Target>


I created a target on the fly using the CreateItem step which also allows me to extend it later if I want to place more items inside it, then just referenced that item and copied it

Wednesday, June 18, 2008

Work Item Templates

My findings on creating and customising your own Work Item Templates in TFS 2008

First off - here is some background reading and resources

Tools to capture “Defects”
http://www.techsmith.com/snagit/accessories/teamsystem.asp
http://ozgrant.com/2006/06/17/tfsbugsnapper/

Extending TFS Templates using TFS Power Tools
http://msdn.microsoft.com/en-us/tfs2008/bb980963.aspx
http://msdn.microsoft.com/en-us/library/ms400654(VS.80).aspx
http://blogs.msdn.com/narend/archive/2007/07/31/nice-trick-to-enforce-certain-rules-on-area-path-and-iteration-path.aspx

Enhancing VSTS – Setting up TFS groups and changing the Bug Work Item Template
http://visualstudiomagazine.com/columns/article.aspx?editorialsid=2046

Differences between WIWA and TSWA
http://www.microsoft.com/downloads/details.aspx?FamilyId=FAED8359-F54D-480E-8A86-F154D3DEA07E&displaylang=en
http://blogs.msdn.com/buckh/archive/2008/04/09/team-system-web-access-2008-sp1-ctp-and-work-item-web-access-2008-ctp-are-now-available.aspx

After I had created my own custom "Incident" my boss didn't want to use Bug as then he couldn't charge for it! I then wanted to delete the templates we don't use so use the following command

C:\Program Files\Microsoft Team Foundation Server 2008 Power Tools>
tfpt destroywitd