Sitecore Swamp

Dive in the Sitecore Swamp

NAVIGATION - SEARCH

Remove TFS workspaces

In command line prompt:

<workspacefoler>\"C:\Program Files (x86)\Microsoft Visual Studio 12.0\Common7\IDE\tf.exe" workspaces /remove:*

note: Visual Studio 12 is Visual Studio 2013

Undo unchanged (TFS)

Visual Studio automatically checkout the file for edit, which is good for convenience. But the file keep the check-out status, even you roll back all the changes. When you try to commit changes, the file will be in the pending list, however it's identical to the server one.

If you have Team Foundation Power Tool installed, you can do the following command to undo the unchanged files:

tfpt uu . /noget /recursive

Even better, create an external tool in Visual Studio to do it in a click:
VS > Tools > External Tools:
Title: Undo unchanged
Command: tfpt.exe
Arguments: uu . /noget /recursive
Initial directory: $(SolutionDir)