Read this book! http://www.amazon.com/Inside-Microsoft-Build-Engine-PRO-Developer/dp/0735626286/ref=sr_1_1?ie=UTF8&s=books&qid=1276690786&sr=8-1
From: oztfs-boun...@oztfs.com [mailto:oztfs-boun...@oztfs.com] On Behalf Of Jakob Ehn Sent: Wednesday, June 16, 2010 3:03 AM To: ozTFS Subject: RE: GetDependsOn You can ”follow” the imports. If you are working with a TFS build definition (TFSBuild.proj), you can see the following import at the top: <Import Project="$(MSBuildExtensionsPath)\Microsoft\VisualStudio\TeamBuild\Microsoft.TeamFoundation.Build.targets" /> This file is located on the build server. $(MSBuildExtensionsPath) evaluates to <DRIVE>\Program Files\MSbuild Same thing for a normal C#/VB.NET project file, but then you can find the target file on your local machine Cheers /Jakob From: oztfs-boun...@oztfs.com [mailto:oztfs-boun...@oztfs.com] On Behalf Of Neil Carey Sent: den 16 June 2010 09:45 To: ozTFS Subject: RE: GetDependsOn Hey, thanks for the reply. I'll look into the TFS extension points and the Get functionality. (Just starting down the MSBuild road). Dumb question, perhaps, but how do I "find" the definition of $(GetDependsOn)? Thanks, Neil. From: oztfs-boun...@oztfs.com [mailto:oztfs-boun...@oztfs.com] On Behalf Of Jakob Ehn Sent: Wednesday, 16 June 2010 5:33 PM To: ozTFS Subject: RE: GetDependsOn Sure, there are lots of these properties in the MSBuild/TFS build target files, and the purpose is to be able to extend the default behavior and insert custom functionality at some point in the build process. For example, in our TFS 2008 release builds, we have defined a build process by extending most of the TFS extension points like this: <GetDependsOn> ReleaseBuildBeforeGet; $(GetDependsOn); ReleaseBuildAfterGet; </GetDependsOn> This will call the ReleaseBuildBeforeGet/ReleaseBuildAfterGet targets before and after the standard Get functionality in the TFS build targets. If you want to call a custom target somewhere inside the Get targets, you need to find the definition of $(GetDependsOn) and override it: <PropertyGroup> <GetDependsOn> BeforeGet; ReleaseBuildBeforeCoreGet; CoreGet; ReleaseBuildAfterCoreGet; AfterGet; </GetDependsOn> </PropertyGroup> There is an important difference between doing this and just implementing the <BeforeGet> and <AfterGet> targets, and that is that you can only have one implementation of a target. This means that if you implement AfterGet in one target file, and then you (or someone else) decides to implement AfterGet in another target file this will override the default implementation. By using the above “pattern” you make sure that your targets will always be called, even is someone implement Before/AfterGet. Hope that helps /Jakob ________________________________ Jakob Ehn Utvecklingschef - http://geekswithblogs.net/jakob Osiris Data Sveavägen 64, 11134 Stockholm Telefon: +46 8 545 252 84 Box 3186, 10363 Stockholm Mobil: +46 70 7995669 Web: www.osiris.no<http://www.osiris.no/> Mail: jakob....@osiris.no<mailto:david.blomqv...@osiris.no> ________________________________ From: oztfs-boun...@oztfs.com [mailto:oztfs-boun...@oztfs.com] On Behalf Of Neil Carey Sent: den 16 June 2010 09:06 To: ozTFS Subject: GetDependsOn Hi All, Would someone be able to point me in the direction of the MS documentation on GetDependsOn? <GetDependsOn> $(GetDependsOn); </GetDependsOn> I've had a look on the interwebs but nothing obvious jumps out. Failing this - most likely :) - can anyone explain what this does? Cheers Neil. ________________________________ Confidentiality and Privilege Notice This document is intended solely for the named addressee. The information contained in the pages is confidential and contains legally privileged information. If you are not the addressee indicated in this message (or responsible for delivery of the message to such person), you may not copy or deliver this message to anyone, and you should destroy this message and kindly notify the sender by reply email. Confidentiality and legal privilege are not waived or lost by reason of mistaken delivery to you. ________________________________ ________________________________ Confidentiality and Privilege Notice This document is intended solely for the named addressee. The information contained in the pages is confidential and contains legally privileged information. If you are not the addressee indicated in this message (or responsible for delivery of the message to such person), you may not copy or deliver this message to anyone, and you should destroy this message and kindly notify the sender by reply email. Confidentiality and legal privilege are not waived or lost by reason of mistaken delivery to you. ________________________________
_______________________________________________ oztfs mailing list oztfs@oztfs.com http://prdlxvm0001.codify.net/mailman/listinfo/oztfs