0

In TFS2013 I'm having the following dilemma, a build has always been dropped to a custom folder defined in the Build Definition. Suddenly, it is now needed to have it available online, so the "Copy build output to server" is the logic option.

However, I can't lose the "normal config", so I was wondering if it was a way to execute both Staging Locations. Tried with the .proj configuration file but I can't see a way to do it.

Any suggestions?

Thanks!

Iceman
  • 463
  • 5
  • 14

1 Answers1

0

You can add a CopyDirectory activity in XAML build process template, or you can program a script to copy the outputs to a custom location in pre-build/post-build.

http://geekswithblogs.net/jakob/archive/2010/09/01/tfs-team-build-2010-how-to-place-the-build-output.aspx

https://msdn.microsoft.com/en-us/library/dn376353.aspx

Cece Dong - MSFT
  • 29,631
  • 1
  • 24
  • 39
  • Hi, maybe I'm missing something, but by the XAML Build Process Template if I have the Output configured for the Server I can't get the drop folder, because it will give an error like this: "Failed to copy. Ensure the source directory #/141/drop exists and that you have the appropriate permissions." I also tried with Environment Variables so I could get the BinariesDirectory but doesn't seem to work. – Iceman Nov 12 '15 at 19:13
  • How do you add CopyDirectory activity in XAML build process template? By the way, do you consider upgrading TFS 2013 to TFS 2015? If you use TFS 2015 or Visual Studio Online, you can use TFS Build vNext, which can add multiple Artifacts Tasks. – Cece Dong - MSFT Nov 13 '15 at 09:57
  • In between "RunOnAgent" and "InvokeForReason", I'm putting there a "CopyDirectory" activity where: Destination -> Parameter defined in the Build Definition. Source -> BuildDetail.DropLocation But then I get that error (which I think is logical since there is no "path" for TFS in-drops. I have been trying with Environment Variables, using: Microsoft.TeamFoundation.Build.Activities.Extensions.WellKnownEnvironmentVariables.BinariesDirectory so I could copy from there to the alternate output, but no luck. Yes, I'm considering upgrading to 2015, but is so different... afraid of migration issues. – Iceman Nov 13 '15 at 12:20
  • By the way, the "DropBinaries" activity does anything? Doesn't matter where I put it, it just does nothing. – Iceman Nov 13 '15 at 12:21
  • "DropBinaries" activity copys the binaries produced by the build to the drop location. – Cece Dong - MSFT Nov 16 '15 at 10:39