0

According to my post: Build Definition XAML -> TFS2015

which is duplicated with: How to handle multiple configurations in VSTS Release management?

I have one more question about Build Proces in TFS 2015. can someone tell me how can I set two outputs path after build? I mean one for x64 bit and second for x32 bit during one build process?

  • ../Release/x64/..
  • ../Release/x32/..

Build Platform is set to "MixedPlatform". I did try also with "Any CPU" without result...

My configuration is in the first link.

pollpbl
  • 53
  • 1
  • 6

1 Answers1

1

I'm assuming you have a multiplier set up on the BuildConfiguration or BuildPlatform variables, or on both, so that the build process runs multiple times for each permutation.

In that case, you just need to override your output path (usually /p:OutDir=(some path)). In this case, you'd override it to $(Build.ArtifactStagingDirectory)\$(BuildConfiguration)\$(BuildPlatform). That will put the outputs for the current permutation of your build to a specific folder for that permutation.

Then, in your publish artifacts task, make sure you're publishing an artifact pointing to $(Build.ArtifactStagingDirectory)\$(BuildConfiguration)\$(BuildPlatform) with a unique name, like Web_$(BuildConfiguration)-$(BuildPlatform)

Then, when the builds are all done, you'll have multiple sets of artifacts attached to the build, one for each permutation. You can then consume those artifacts down-stream in a release definition.

Daniel Mann
  • 57,011
  • 13
  • 100
  • 120
  • I did write in MSBuild Arguments: /p:DeployOnBuild=True /p:PublishProfile=Build /p:OutDir="$(Build.ArtifactStagingDirectory)\$(BuildConfiguration)\$(BuildPlatform)" /p:PipelineDependsOnBuild=false and I did set in variable: BuildConfiguration: Release BuildPlatform: Mixed Platforms I need something like that: BuildConfiguration: Release, Releasex64 BuildPlatform: Mixed Platforms, x64 but it doesn't work... – pollpbl Apr 27 '18 at 07:09
  • I have to run ONE build with two command options: Release|Mixed Platforms and Release|x64 during one Build. How can I set that? – pollpbl Apr 27 '18 at 07:22
  • @pollpbl Look at the second link you provided in your question. It explains how to set up build multipliers to run the same build multiple times for different permutations of configurations. – Daniel Mann Apr 27 '18 at 17:34