开发者

How do I recover a removed branch in subversion?

A branch got removed from our repository, and now we think it h开发者_JAVA百科as code we want to keep after all...

command line, Tortoise, SmartSVN, all good...


Copy the revision before it was removed, this will restore the branch as it existed in [REVISION] to the HEAD revision.:

svn copy -r [REVISION] http://svn/path/to/branch http://svn/path/to/branch

Edit: Clarification added thanks to Michael Hackner.


This is the same thing as MarkPowell's answer, but specific to TortoiseSVN.

View the log for the branch's parent folder, find the revision you want, right click and choose "Create branch/tag from revision", right at the bottom of this screenshot:

How do I recover a removed branch in subversion?


Can't you use repo browser and go back a couple revisions?

Am I missing something?


Is the server a Unix box? If so, you can try plugging it into another machine and then without mounting it, dd the contents of the device to a file... You could then use a combination of strings and grep to locate the bits of value... Though this is tedious and not much fun...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜