Our source control is on a hyper-v virtual machine, and last night a snapshot-merge of t开发者_开发百科he image went horribly wrong. The source control server now contains a months-old version of the source; all changes since have been lost.
By the way, if your source control is on a virtual machine, back up the database before you do anything with the machine image, mkay?
I want to forcibly push my current workspace back onto the server, the reverse of doing a Get Specific Version with the "Overwrite all files" checkbox checked.
Currently, the only way I can think of to do it is to branch, delete everything, re-add everything, then merge. PITA.
I am not sure if this will actually work, since I don't have a TFS project that I would try it on. But here is what I would try, if I found myself in your situation.
- tf checkout /recursive to check out all of the files that you currently have in source control
- tf add /recursive to add all of the files that were added over the last month
- tf resolve /recursive /auto:KeepYours to handle the all the conflicts that come up.
Why don't you rollback the checkin?
See the tf rollback documentation on MSDN
精彩评论