static void

TFS 2010- workspaces, team projects

Published Sunday 13 December 2009

Team Foundation Server 2005/2008 didn't make much sense for small teams. TFS 2010 Basic allows you to have a simple, quick source control and issue ("work item") tracking for individuals. It should at least see the end of SourceSafe. Whether it will draw back those who have already jumped to subversion remains to be seen.

Creating workspaces and team projects is not something I'll do very often, so I'll record the steps here.

Download VS2010 and TFS 2010 from Microsoft and install. The TFS configuration wizard kicks in after the install, and is pretty simple.

Connect to TFS.

connect to tfs Spot two ways to do it in this screenshot.

Select TFS server - click "Servers" button

select tfs server

The servers list will be empty at first so click "Add" button

select tfs server 2

Fill in the server name.

select tfs server 3

Now the project collection is shown (always DefaultCollection with basic). Click "Connect"

select tfs server 4

Workspaces

You need to set up a workspace - the local path on your computer (in VSS this would be your "working directory").

In VS2010, File-Source Control - Workspaces.

file-source control-workspaces

It's empty to start. Typically you only have one per TFS server. Click "Add"

tfs workspaces

Map the server folder ("$/") to your local folder (here, C:\Dev)

tfs workspaces 2 

New Team Project

Each TFS contains a number of collections (these root collections are new in 2010), Each collection contains a number of team projects. The team project is typically an application, comprising one or more solutions plus work items and documents. More information here (Codeplex guidance)

You can start a team project from the VS2010 File-New-Team Project or the team explorer.

new team project

It's a simple wizard. Name it, pick the type (you may have a Scrum template), Next, Next, Next.

new team project 2 new team project 3 new team project 4 new team project 5

new team project 6

Your source control is now empty. Don't just put a solution in there. Add New Folder, and use this to put your first code in. I'm calling it Trunk, but TFS people seem to call it "Main".

new source control folder

I created a Visual Studio solution within my workspace\project\trunk folder. I add it to source control.

add solution to source control

And check in (pending changes window)

pending changes

Why a subfolder called "Trunk" (or "main")? So I can create a branch.

I also create a "Branches" folder under the team project, and branch to a subfolder of that. Here I'm creating a branch for a new version (v4).

branching

There's detailed guidance on TFS branching on Codeplex.

Previously: ScottGu Lineup (12 Dec 2009)