Search code examples
tfsazure-devopstfvc

TFS Branching / Versioning Basics


I am very new to TFS. I have below Structure where I have my entire SOLUTION checked into my TFS online Repository.

enter image description here

Now, we are done with this Feature/Version.

What we want to do is...Leave this version AS IS and create a new Version / Branch out of this. This way if we ever have to go back to this version we can easily go back to it.

But Whenever I right Click on Root and Choose "Branch" Then I get an error that "The Bracnh Already Exists". I would like to name the new Branch "Release 2.0" or Something. But I cant Branch out my current Solution.

Creating New Folder option is Disabled.

enter image description here

Why is it disabled? I have full access to TFS/


Solution

  • You can't branch from the team project root. Reorganize everything to be in a trunk folder (TFVC convention is main, but you can call it whatever you want), and branch off of that.

    For what it's worth, branches shouldn't be infinitely branching -- you should branch off of a trunk to do development, then merge back in when development is done. There are numerous reasons why this is the case, but I suggest doing some reading on TFVC branching strategies to find one that's appropriate for your organization.