Fixing Missing Folders in my Subversion (SVN) Repository
Sounds almost dirty, doesn't it?
I've been working some more with the Wordpress PODs CMS plugin this week, and I'm really begining to appreciate just how good it is. I am now at the point where I'm having more difficulty customizing the Wordpress pages then theming my own PODs CCK.
Something unusual did happen to me though - folders went missing from my subversion project!
I was transferring SVN dump files between machines, and the whole site collapsed. My Zend CE log told me this was becuase the PODs plugin was missing - what the hell?
Here's what went wrong.
I copied my PODs plugin from another Wordpress plugin that was part of a checked-out repository. This included the .svn files from the other project. The result? Subversion got confused and didn't include these files in the project. I have also noticed that if you move folders inside the same project that are under versioning (contain the .svn folder) you get the same problem.
It is a simple problem to address.
First of all, try using a GUI like Tortoise SVN. This tool provides a 'move here' function which understands and adjusts versioning (thank you Daniel for this pointer). If the folder is outside the project but under versioning, you can also use 'export' (again using Tortoise SVN) to move an unversioned copy of the folder to the desired location.
If you have already made this mistake, try deleting the .svn folder inside your versioned folder. This may give you errors about unversioned files. In this case, rename the folder, clear out any .svn folders inside, then commit. This will delete the old folder reference, and then create the new one. You would then rename the folder and commit again. If this doesn't work, you may have to run the cleanup script.
This last solution is pretty messy, but it will let you fix the problem quickly and get on with your work.


Comments [0]