Is it possible to store the list of Projects to Build in an external file for TFS2010 build definitions?

StackOverflow https://stackoverflow.com/questions/8414880

  •  29-10-2019
  •  | 
  •  

Question

I have a legacy build definition that was set up before I started my job that builds a solution file. Now, according to this article, MSBuild completely ignores the build order set up for the solution so I have created a new build definition that builds the solution's project files in the correct order as per the solution's Build Order. Whilst this gets around my initial problem, it took a long time to set up the list of projects to build for my build definition as the solution has over 100 projects and entering all of these projects via the UI was a bit of a pain.

An ideal solution to this issue would be if the build definition could reference an external file that holds this list of projects to build. This would also help me in the fact that the developers could also update this list with any newly added projects that need to be built with the correct building order too.

Does anyone know if this is possible and if so how to achieve this?

Was it helpful?

Solution

If you look in your TFS_'CollectionName' database, @ table tbl_BuildDefinition there is this column ProcessParameterswhich holds in XML all the different build definition params.

The subsection you 're after looks like this:

 <mtbwa:BuildSettings x:Key="BuildSettings"
  ProjectsToBuild="$/../solution1.sln,$/.../solution2.csproj">

So the different project to be build are kept here (comma separated).

It should be possible to construct a tool that retrieves & edits this field, even do this tool operate on an input file-basis - just like you 've set as ideal.

On the other hand, MS-people have more than often stated that direct access to TFS-DB is not advised - not supported etc.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top