Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

TFS: Labels vs Changesets

I am trying to come up with best practices regarding use of TFS source control. Right now, anytime we do a build, we label the files that are checked into the TFS with the version number. Is this approach better or worse than simply checking the files in and having the version number in the comments? Can you then use the changeset to go back if necessary or the labels are still more versatile?

Thanks!

like image 371
laconicdev Avatar asked Jun 05 '09 15:06

laconicdev


People also ask

What are changesets in TFS?

Changesets contain the history of each item in version control. You can view a changeset to see what the exact file changes were, discover the owner's comments, find linked work items, and see if any policy warnings were triggered.

How do I add a label to a changeset in TFS?

If you right click in source control explorer and select -> find -> find by label, then select your label and click edit, you'll see a list of all files in the label and the changeset of when they last changed prior to the label changeset.

How do I find labels in TFS?

In TFS 2008 you can view label information by: Selecting a folder or file in Source Control Explorer. Proceed to the menu bar and select File -> Source Control -> Label -> Find label.


1 Answers

They have two different purposes, ChangeSets are when the files have actually changed and you wish to keep a permanent record of that change. Labels mark a certain version of the files so that you can easily go back to that point. Unless your build actually changes files under source control and you wish to record these changes. You should be labeling.

Also, labeling is much less resource intensive. And you can have multiple labels on the same version of a file.

like image 64
Alex Avatar answered Sep 23 '22 18:09

Alex