views:

90

answers:

3

Hello,

I am trying to check in a project to svn. However, I get an error message stating that this is locked. I am the only user. I tried to "clean" my project. No change.

Is there a way to force unlock?

A: 

SVN does have a lock feature, but likely you didn't use that. If you did you just need to unlock first.

Perhaps you should just delete (or move to your desktop) the locked folder and then do an svn update to fetch the latest folder.

If you have changes you can copy them back in by first deleting the .svn folders in your copied folder and then pasting on top of the newly checked out files.

Normally an svn clean will fix these things but I've seen sometimes where I had no other choice but to do the above.

(Note: close visual studio before you do this)

Brian R. Bondy
+2  A: 

This probably means your working copy is locked. Please provide the full error message for further analysis.

A locked working copy will result if you force-terminate an svn command or the command errors out uncleanly.

The quick fix is to run svn cleanup. This normally fixes broken working copies.

Mike Miller
+1  A: 

you can also go into the .svn directories and remove the lock file.

derek
How do I remove the lock? I removed the .svn directory. no change
do a search in all .svn directories in your solution for files named lock. Even one existing in a nested folder can cause the checkin to fail.
derek
If you removed the .svn directory, you've also removed the meta-data required to associate the files in that folder with the repository. This is no longer a valid working copy.
ThatBlairGuy