0
votes

I'm using MSBuild with TFS and I have to build 4 solutions. When the compilation is done I should launch upon to 4 different Exec tasks depending on wherever the compilation was successful or not.

I know how to do that with MSBuild alone using targets with conditions using the var $(BuildBreak) because I can do build solution - check result - exec task - build ... but I don't know how to do that with the TFS extensions ... any help will be very appreciated.

Thanks mates.

3

3 Answers

2
votes

With TFS, the idea is to hook into the TFS eventing service. This guy did it here for his project. I can't provide too many details as I am just getting started with TFS, although I am sure its not too far off from dealing with a normal webservice. You should be able to find the details on the eventing service here

1
votes

You can use the same targets and conditions with TFS. To implement automation that gets invoked only when building with TFS, you can check for the BuildingInsideVisualStudio property - it's only defined when (you guessed it) you're building inside Visual Studio.

1
votes

I had to check the AfterCompileSolution target defined into the TFS Build extensions