[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

Corrupt .svn directories

From: Robin Pellatt <pellatt_at_mirocs.com>
Date: 2005-06-01 12:49:32 CEST

Hi Folks,

I have what I think might be a reasonably common problem, but so far
haven't found a good solution. So...

My situation is this:

----------------------------------------------
D:\Projects\XXX>svn up
svn: Working copy '.' locked
svn: run 'svn cleanup' to remove locks (type 'svn help cleanup' for details)

D:\Projects\XXX>svn cleanup
svn: Can't open directory '.svn/tmp': The system cannot find the path
specified.
----------------------------------------------

Now I know this is because some of my .svn directories have been
corrupted (my own fault).

However there doesn't seem to be a clean way to recover from this, and I
know I'm not the only one who has done this.

I've looked through the book, the FAQ, the mailing lists, and Googled,
and the recommended solution seems to be just to move the whole working
copy somewhere, check out a clean copy, and copy across any changes.
OK, fine, I could do this, I've got maybe 20 files changed across a few
directories, it wouldn't take *that* long.

But it seems to me that Subversion actually has all the information it
needs to recover from this situation. All I actually want to do is
force it to recreate all my .svn directories, without messing with my
changed files. So maybe a command something like:

svn recover

or

svn checkout --recover

This would be similar to a checkout, except for two differences:
1. It would completely ignore any .svn directory already existing, and
simply overwrite these with new ones.
2. It would not check out any file that already exists, but merely make
the relevant entry regarding it in the .svn directory in the usual way.
Files that don't exist will get checked out.

With this, I would now have exactly what I had before, plus the
equivalent of having done 'svn up'. This sounds to me easy to
implement, and would, I think, be really useful, so what do you guys think?

Cheers,

Robin.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@subversion.tigris.org
For additional commands, e-mail: users-help@subversion.tigris.org
Received on Wed Jun 1 12:51:37 2005

This is an archived mail posted to the Subversion Users mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.