1

I had to wipe our svn server, but I failed to "dump" the repositories before installing a new OS. However, I had a complete backup of every file in each repository. I've since transferred all the old files back over. Unfortunately the version history is completely gone. I still have all the old incremental files, and svn can see each revision with the "verify" command, but I'm wondering if it is possible to import the old history directly from the actual files (not a dump file)?

0

Unfortunately I don't think the information exists. You can try running a grep in the .svn directory of one of your working copies (I assume that's how you have a copy of the files) for strings from old log messages. If you find them I'm sure we could work up a script to repopulate the log history, but the file version history is certainly gone. I just poked around at mine and I don't see the log history being saved in the working copy either.

I think the best you will manage is to build a repository with a blank commits up to the version number of whatever copy you have. That way any references to revision numbers will still be valid, they will just be blank.

0

At this point you're best off starting over with a fresh repository - you could try inserting dummy revisions into a tree, but it'll invalidate working copies anyway and lead to weird problems with svn log/diff/etc. It's a lot safer to do that than to try and massage things together in some clever way.

If you have all the historic versions of the files, you could write a script to create new revisions based on the old versions of the files to have the old versions, but you'll lose all the other metadata from each revision, like the date, author, and log message.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy