Naming your TFS workspace

Working with TFS workspaces can be confusing at first, especially if you use more than one and manage multiple workspace mappings. Typically users who work in two lines of development, such as a branch line and a trunk line, manage these development lines in separate workspaces. The best way to keep track of which workspace corresponds to which line of development is to give each a meaningful name.

While there is no official naming convention for TFS workspaces, some developers consider it a good practice to give workspaces a name that includes your machine name, your deliverable, and branch if applicable. Using your computer's name makes it easy for other team members to see at a glance which computer (and therefore which contributor) a workspace belongs to. Including your deliverable helps if you work on more than one Team project. Including the output location helps you keep track of which line of development a workspace belongs to. This can be of great value when you have a project with the same name in both a branch and a trunk line of development.

Example: If your computer name is mycomputer and your deliverable is software project name which you are uploading to (or downloading from) a trunk location, you would name your TFS workspace: mycomputer_projName_trunk. This will be the name other users see in their Properties / Status window when you have a file checked out for editing.

Examples throughout this user guide show a user (Keith Moses) who's a technical writer for a Team project named Media_Mill Plug-in, who uploads to both a trunk and a branch location. Therefore, his TFS workspace names are:

When you login to TFS for the first time, Teamprise creates a default TFS workspace with the name of your computer. You can edit this and give your workspace a name of your own choosing.

Naming and mapping rules

When naming TFS workspaces, it's important to keep the following two rules in mind:

  1. You cannot have two TFS workspaces with the same name, even if they point to separate projects, or computers. For example, assume you create a workspace named "test-workspace," TFS won't allow you (or any other user) to create a second workspace also named "test-workspace." You also won't be able to log into TFS from a different computer and create a workspace with that name.

  2. You cannot have two TFS workspaces where each maps to the same local Eclipse working directory even if the workspaces are owned by different users. For example, assume user "User1" creates a TFS workspace named "test-workspace" and maps it to a local path of c:\workspace."User1" won't then be able to create a second TFS workspace that also maps to c:\workspace.

Related Tasks:

Creating and removing a TFS workspace
Adding a working folder mapping to a workspace
Switching TFS workspaces