Search code examples
workspace

TFS: Can a workspace be migrated to another computer?


I have one workspace A with files checked out on computer A. Now I want to continue development on computer B. I copy the files from computer A and creates a new workspace B with mapping to the copied files.

Now Visual Studio wont allow me to check in the files since they are already checked out in workspace A.

How can I resolve this without having to check in the files first on computer A?


Solution

  • Create a new workspace on B, copy the directories over from A and use team foundation power tools 2008 to checkout all modified files:

    Open a cmd window, then

    cd c:\wherever\your\workspace\is
    tfpt online /recursive /adds /deletes /diff .
    

    tfpt will analyze a directory tree and checkout any modified file for edit (and optionally also "add" or "delete" files as necessary.)

    make sure you verify what tfpt did, before you check in