tags:

views:

184

answers:

3

after a major server fault, svn repository was destroyed and my working version is most current one,

what is the way to recreate svn repository from my working version?

after installing svn on a new server and trying at my working copy

 svn switch NEW_SVN_PATH .

i get an error

 Repository UUID '1c604742-6b16-462b-86e4-cc8bce959242' doesn't match expected UUID '6df69aeb-a72c-450d-8102-24036a3855f7'
+3  A: 

If you wish to recover your history, you are out of luck... SVN history is kept in the repository, not the working copies...

If you want to start a new repo with the data in your working copy (just the files, not the history) you can do that with svn import and svn export:

svn export <wc-path> <clean-dir-path>
svn import <clean-dir-path> <empty-repo-url>
Martinho Fernandes
+3  A: 
  1. The development history that was stored in your old repository is lost.

  2. You can create a new repository with the current contents of your working copy, but this will truly be a new repository. You can't switch to it, not even with --relocate.

If you've already managed to import the contents of your working copy into the new repository, you just need to check it out. If not:

svn export WORKING_COPY WORKING_COPY.export  # the exported copy will contain no .svn dirs
svn import WORKINGCOPY.export svn://example.com/new-repository
svn checkout svn://example.com/new-repository NEW_WORKING_COPY
bendin
A: 

I would clear out the .svn folders in your working folder before (doing what others suggesting) creating a new repo. I'm only saying this because I've had a couple of problems in the past that confused either my new repo or my client. Good luck!

Nick