Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How do I revert a file in TFS

On occasion, I'll end up checking in a file to our TFS db that I didn't intend to. Reverting to the prior version is quite tedious with my current approach.

If there a fast way to revert a file to a prior version in TFS? I'm open to command line, powertool, or UI approaches.

like image 925
Scott Weinstein Avatar asked Jan 14 '09 22:01

Scott Weinstein


2 Answers

You need to install the power tools:

http://msdn.microsoft.com/en-us/tfs2008/bb980963.aspx

  1. For VS2013 - Microsoft Visual Studio Team Foundation Server 2013 Power Tools
  2. For VS2015 - Microsoft Visual Studio Team Foundation Server 2015 Power Tools
like image 145
Iain Holder Avatar answered Oct 04 '22 03:10

Iain Holder


If you don't want to use the command line, or install the tools, you can also do it in an old-school way:

http://msmvps.com/blogs/vstsblog/archive/2009/01/10/how-to-revert-changes-checked-into-tfs-version-control.aspx

like image 20
Peter Walke Avatar answered Oct 04 '22 04:10

Peter Walke