Reputation: 131408
I have a Mac project in XCode that is in a subversion repository.
Subversion is set up on a remote server using svn+ssh.
I made several attempts to add a nested group of directories to my project, and had to delete and re-add the top-level directory a few times in getting it to work.
In so doing, I forgot about the ".svn" files that subversion leaves at each level of your project hierarchy in order to keep track of the state of the check-out in the repository.
I had used the XCode "add to repository" command to add the first version of my sub-directory to my working copy.
Now, when I try to check in a round of changes, I get a very un-helpful error:
"Error: 155005 (Working copy not locked; this is probably a bug, please report) Description: Commit failed (details follow): Error: 155005 (Working copy not locked; this is probably a bug, please report) Description: Directory '/Development/FractalWorks/FractalWorks Plots/.svn' containing working copy admin area is missing"
I need to figure out how to back out my add commands and get my working copy into a state so that I can check in my changes to the repository.
I'm fairly comfortable working in terminal and issuing svn commands there. I also have a registered version of the "versions" app, although I am not currently using it to manage this project.
Can somebody point me to some information on how to clean up a working copy, remove the vestiges of the "add to repository" commands that I did, so I can add the final subdirectory of files to my project and get it to commit?
I find svn opaque and very hard to navigate, and the manual is not very informative. I have not seen any info on how to handle a case like this when the working copy gets out of sync with the repository. Any help would be greatly appreciated.
Upvotes: 1
Views: 5637
Reputation: 86651
svn revert file-i-added
will back out adds.
However, the easiest way to get out of a situation like this is simply to check out a clean working copy. What you should do is:
When doing the third step, take care not to replace directories in the new working copy with directories from the old working copy. Copy the content instead. If you find whole directories missing from the new working copy, you can recursively copy the directory from the old working copy and then svn add
the whole tree. But make sure you do not copy any .svn
directories from the old working copy. In fact you might want to run the following on your old working copy (make a back up first)
find old-working-copy-dir -name '.svn' -type d -exec rm -rf {} \;
Upvotes: 2