0
votes

I am in the process of converting an old TFS XAML build definition to the new build mechanism in TFS2018. In the old definition i was able to build multiple projects by filling in the Projects to build items in default build template and separate the projects with a "," comma.

$/WMS/Dev/sekoWMS/DPURevisionUpdater/DPURevisionUpdater.csproj,$/WMS/Dev/sekoWMS/DesktopApp/SEKOWMS/SEKOWMS.csproj

I have a new build in TFS 2018 and when I specify the same arguments in the solution line of the "build solution task", I get the following compiler error:

"C:\agent_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.120.0\ps_modules\MSBuildHelpers\vswhere.exe" -version [15.0,16.0) -latest -format json "C:\agent_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.120.0\ps_modules\MSBuildHelpers\vswhere.exe" -version [15.0,16.0) -products Microsoft.VisualStudio.Product.BuildTools -latest -format json "C:\Program Files (x86)\Microsoft Visual Studio\2017\BuildTools\MSBuild\15.0\Bin\msbuild.exe" "C:\agent_work\3\s\Dev\Dev\sekoWMS\DPURevisionUpdater\DPURevisionUpdater.csproj,$\WMS\Dev\sekoWMS\DesktopApp\SEKOWMS\SEKOWMS.csproj" /nologo /nr:false /t:"Clean" /dl:CentralLogger,"C:\agent_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.120.0\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll";"RootDetailId=58de9b3f-5678-49d1-8fd4-e40a7fda7f3f|SolutionDir=C:\agent_work\3\s\Dev\Dev\sekoWMS\DPURevisionUpdater\DPURevisionUpdater.csproj,$\WMS\Dev\sekoWMS\DesktopApp\SEKOWMS"*ForwardingLogger,"C:\agent_work_tasks\VSBuild_71a9a2d3-a98a-4caa-96ab-affca411ecda\1.120.0\ps_modules\MSBuildHelpers\Microsoft.TeamFoundation.DistributedTask.MSBuild.Logger.dll" /t:UpdateRevision /target:publish /property:PublishDir="\harmonywebdev.admin.sekoww.com\SEKOApps\sites\Downloads\SEKOWMSUtilityDev\" /property:InstallURL="http://harmonywebdev.admin.sekoww.com:9300/SEKOWMSUtility... MSBUILD : error MSB1009: Project file does not exist. Switch: C:\agent_work\3\s\Dev\Dev\sekoWMS\DPURevisionUpdater\DPURevisionUpdater.csproj,$\WMS\Dev\sekoWMS\DesktopApp\SEKOWMS\SEKOWMS.csproj Process 'msbuild.exe' exited with code '1'.

Is there a way to specify multiple projects (from different) directories so that they compile correctly?

2

2 Answers

1
votes

New build system doesn't support comma to separate the projects, it only supports Wildcard. Including @Daniel's suggestions, you could also try the steps below:

First, map all projects that you want to build:

enter image description here

Then, specify **\*.csprojin the build task:

enter image description here

0
votes

Here are some options:

  1. Use a solution file
  2. Use multiple build steps
  3. Create your own custom msbuild .proj file