13
votes

I'd like to recreate a folder hierarchy like in this example (from TFS Branching Guide Main 2010 v1): enter image description here

The problem is I cannot understand how to create additional root-level folders, like those Development and Release in the picture above, to put new child branches into.
The New Folder command option becomes available only at levels beneath root-level branches.

How to create new root folders in a Team Project source control at the Main branch level?

3
Which of the folders above are you calling "root-level"?John Saunders
I agree with John here about the need for disambiguation. Just for future reference, in TFS terminology, $/ is the "server root path".Edward Thomson
Maybe you are right about an ambiguous usage of "root-level" term in this context. But, please, look at this Microsoft's Patterns&Practices "How To: Structure Your Source Control Folders in Team Foundation Server" article (the "Overview" section) msdn.microsoft.com/en-us/library/bb668992.aspx Perhaps, in this case it can be called root-level in relation to the Team Project (as the Title of the question implies) rather than being the "server root path". But, if I'm wrong, it's ok for the community to edit my post. I agree all questions should be as clear as possible. Thanks!rem

3 Answers

23
votes

Make sure that your workspace maps at the Team Project level ("StandardBranchPlan" in the picture). I just tried this, and found that "New Folder" does not appear if I have the wrong workspace selected, but once I select a workspace that maps the folder under which I want to create a new folder, "New Folder" became enabled.

3
votes

Here is what I did.

  1. Connect to the desired collection in Team Explorer.
  2. Click the down arrow at the end of the "Connect" row.
  3. From the drop-down menu provided select "Projects and My Teams".
  4. Select "New Team Project".

And now you have a new "Directory" under the collection root.

1
votes

You cannot add a folder to root in TFS to an unmapped as mentioned. However one good way to do this is with the following example.

Scenario:

  1. You want to have a NEW Folder to contain many NEW Projects
  2. Right click on your solution and Add solution to source control
  3. At this point you can create a folder on root with say name of "WebServices"
  4. Then you continue through with the popup in adding in your project/solution

For me this works fine, although I too would prefer the freedom to setup a folder structure ahead of time for myself and other developers without having to commit /checkin code etc...