Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How can I find all of the labels for a particular TFS project sub-folder?

Tags:

tfs

tfvc

Assume there is a TFS project Project with the subfolders trunk and 1.0. trunk contains the latest version of the application code for this project and 1.0 contains the code for the same application for the released version of the same name.

There are labels for both sub-folders and all of the labels include files in only one of the sub-folders. [You could also assume that the labels are recursive on a specific (maximum) changeset for all of the files in the entire sub-folder too if that simplifies your answer.]

How can I create a list of labels for one of these sub-folders, using Visual Studio, the TFS tf.exe command line tool, or any other tool or code that is publicly (and freely) available.

Note – I've written T-SQL code that queries the TFS version control database directly to generate this info, but I'm curious whether there are 'better' ways to do so.

like image 505
Kenny Evitt Avatar asked Apr 04 '12 18:04

Kenny Evitt


2 Answers

In Visual Studio, in the Source Control Explorer window, right-click the sub-folder for which you want to list the relevant labels and pick View History from the context menu. In the History window that should appear, there should be a sub-tab Labels (as highlighted below) that lists labels applied to that sub-folder (but not specific items in that sub-folder).

enter image description here

like image 89
Kenny Evitt Avatar answered Oct 19 '22 10:10

Kenny Evitt


To find labels in Visual Studio

  1. Open Source Control Explorer.

  2. In Source Control Explorer, open the shortcut menu for the collection, team project, branch, folder, or file that you are looking for.

  3. Select View History. You will see a new window with all the Changesets.

  4. Select Labels in the tab menu as highlighted in the below image.

enter image description here

like image 44
Sundeep Avatar answered Oct 19 '22 10:10

Sundeep