• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 1947
  • Last Modified:

In TFS Source Control, is there a way to "undo" checkins to roll-back/recover the server source to a specific changeset?

One of our developers managed to pooch the directory structure on one of our TFS Source Control projects such that the files are invisible/inaccessible in Source Control Explorer.

Is it possible to "undo" checkins, or recover/restore the servers' version as at a specific changeset? ...without affecting other projects on the same server?
0
andrewclarkis
Asked:
andrewclarkis
  • 2
1 Solution
 
Mohamed OsamaSenior IT ConsultantCommented:
Basically TFS does not provide a native method to do this , when we wanted to rollback o a previous version we used to Checkout the item we need to rollback , then GET the specefic version we wish to restore to in a different workspace, copy its contents to the first workspace and checkin, this should work formodifiedĀ  files / projects but not for folder structure like in your case
however with the release of Team foundation power tools , you can rollback a changeset using the command tfpt rollback /changeset:X
where X is your changeset number, you have to have Team foundation power tools installed
- open visual studio command promptĀ 
- CD to your orkspace folder
- type the command as above tfpt rollback /changeset:X

Notes:
-you must not have any pending changes for this to work
-The tfpt rollback command will enforce a get latest before rolling backĀ 

Please post back should you have any further question or run into any difficulties.


0
 
andrewclarkisAuthor Commented:
Thanks!!! We were unaware of that tfpt command. That sounds perfect! Unfortunately we may not be able to attempt this until tomorrow; stay tuned.
0
 
andrewclarkisAuthor Commented:
Perfect, thanks!! I forgot we even had Power Tools. That's exactly what we were looking for.
0

Featured Post

Learn to develop an Android App

Want to increase your earning potential in 2018? Pad your resume with app building experience. Learn how with this hands-on course.

  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now