index > Team Foundation Server - Version Control > Roll back to a file version / Delete an unwanted checked in.

Roll back to a file version / Delete an unwanted checked in.


Hi

After checked in some files to TFS, I am lookin at one file history and would like to roll back to one of them, I was looking for 2-3 options:

1. Delete the unwanted revision and in this method rooling back to previous revision.
2. Merge from history revision to top of trunk and getting back a version from history to top of trunk (with full tracking - the best way in my opinion)
3. Rool back to a revision - move the selected revision to the top of trunk or any other solution.

What are TFS options to do that ?

Thanks,



CM Consultant
Demix

G'day,

From the options you have specified:

1. It is not possible to remove revision from history in TFS

2. I do not quite understand what you mean by merging within file history; history is not a subject to branch/merge operations

3. There is TFS power toy application that supports Rollback operation (which looks as the one you want). Have a look at Buck Hodges blog for details.

Hope that helps.

Yours truly, Eugene




Blog at http://teamfoundation.blogspot.com
eugene.z

HI

Very strange - every problem or need in VSTS is solved by a 3rd party utility/script.

Roll back looks for me a basic operation in source control (I have a backround with lots of tools) if this simple operation is so complicate to do , I think VSTS is not ready yet.

Somtimes , I want to have the flexability to take a history version rolloing it back or merge it to the top of trunk or other branches - should be simple like in other tools.




CM Consultant
Demix

I think the key word in your post is sometimes - rolling back to specific revision is not that frequent operation. Undo latest change on the other hand is readily available.

And as for 3rd party utilities - if they are readily available and solve the problems, I think that may be to the tool advantage rather than otherwise. From my personal experience, while there are some features not available out of the box, TFS is extensible to a very high degree. Of course, that's my personal opinion.

Yours truly,




Blog at http://teamfoundation.blogspot.com
eugene.z

I think you are mistaken - rollback is a natural operation. I don't say it should be frequent but it shouldn't be that painful how it's done on TFS v1.

In waterfall rollbacks are sinonim of a disaster because changes are painful as painful current TFS Version Control wroflows.

In agile environment course switching are naturally embraced and hence should be supported. I am not talking here about rolling back a bunch of bad code - when you have good policies and continuous integration, such a code shouldn't even never get to the version control database. I am talking about rolling back on user request. If you have two-weeks iterations it's OK to allow user to change his/her mind sometimes. Current TFS version control doesn't support truly agile development process.

And a thing I don't llike in TFS (in this rollback situation inparticular): Microsoft again tries to dictate me my process. Please don't! Dev teams could decide what's natural for the process and what's not by themselves...

laboremus
Rolling back a change that's not the latest is going to be complicated regardless of whether TFS adds a specific feature for it. As the original poster notes, it will require a 3-way merge. Let's say the file history looks like:

100 <- last known good
...
120 <- change we want to rollback
...
130 <- unrelated change
132 <- unrelated change
...
[latest]

In this case, we want to pass the following to our 3-way merge program:
base = 120
theirs = 100
yours = tip

In TFS you'd do it like so:
tf view file;120 > base
tf view file;100 > theirs
tf view file;T > yours
diffmerge /merge theirs yours base output

That's exactly what tfpt does. If you're lucky there won't be any conflicts; if there are, tfpt will launch your configured diff/merge tool. Frankly I don't see how to make the process any simpler without compromising safety -- nothing involving 3-way merges should ever be trusted to a completely automatic process.
Richard Berg MSFT

This is hillarious, rollback not a regular thing? So because it is not a regular operation is that why it is not included? I can name you a thousand other features in TFS which is definately not a regular feature, yet it is included. Are you telling me our company had to pay thousands of dollars for a source control solution which cannot even support a basic feature such as rollback to version 'X'???? This is bad man, I mean really bad.

I am beginning to question the design brains at M$, geez. Who would have thought of a solution that can tell you where you are coming from but gives you no option to go back there? It is a basic feature in Visual Sourcesafe?!?

Very dissapointed here.

Rykie
reply 7

You can use google to search for other answers

 

More Articles

Newbie: editing a branch
Writing Filters (VSEFL)
Database Size After Conversion
Build checks out and locks local project output dlls?
TF15013: The requested team foundation server is not registered w...
Checkin Comments
Branch from a label - why didn't this work?
Putting SQL Server DB Objects under Version Control using Team Fo...
Retrieving the workitem delta between two labels
Unshelving and merging changes
Welcome to Bokebb   New Update   Joins the collection  
 

New Articles

Create Folder structure within a project.
Modest request regarding refreshes
Slow VS 2005 performance
Source control check type
Unable to use SourceSafe & TFS on th…
How to "perminately" delete a …
automated release notes
Source COntrol Administration
Unable to add code to Source Control (to…
Removing old versions
Bug: Merging VS Solutions / Projects
Command line
Checkin Comments
Check-in from different directory
Merging: How is the target branch determ…

Hot Articles

Could internal Version Control be replac…
Synchronizing current file in Solution E…
TF Workspace command-line
Multiple Source control Databases in TFS
unshelving changes
Merge / commit not committing all pendin…
VSS Migration Error
Getting latest versions for non-labeled …
tf get latest to a specific location
TF.EXE difference command and versionspec
Code Sharing And Shelvesets
Unable to check-out some files
Merged directories: How to? Impossible?
Weird Compare Issue
code migration - mapping users that don'…

Recommend Articles

Unshelving and merging changes
Xml documentation file checkouts / TeamB…
Proxy Install Troubleshooting
New Projects do not get retrieved on get…
Migrations from 2003 to 2005
History information doesn't show up afte…
Generate list of merge conflict
Deep history - anyway to get it all?
Trouble using both VSS and VSTS
Connect to a TFS as a different user
Newbie question...... How to get startin…
I've deleted my local files, and I'm una…
TF60032: The VSS Converter requires Vis…
Could internal Version Control be replac…
How to handle large numbers of projects …