2008-02-19
Remove .svn folders
This is just another svn hack. On the Mac, when copying a Keynote/Pages/Numbers or similar document that is under subversion control, you also copy all its .svn directories. A similar problem to the one I described in this post. Again, a litte shell script can help here. svnCleanAllSvnFolders simply removes all .svn folders inside the current directory—if you call it with "yes" as a parameter; otherwise it just prints out what it would remove.
2007-07-16
Restore .svn in Keynote/Pages documents
Subversion stores its metadata in a directory called ".svn" that lies in every directory under version control. Keynote, Pages, and some other applications on Mac OS X store their documents in directories that look like files in the Finder. However, for Subversion they are normal directories and as such contain a ".svn" when under Subversion control.
Unfortunately, Keynote/Pages delete the ".svn" metadata-directories when a document is saved. This breaks Subversion: on the next commit or update you get the error "containing working copy admin area is missing". This bug is known since years but has not been fixed.
As a workaround, I've written a shellscript that restores the deleted ".svn" files. You can download it here.
Update 2008-09-16: I fixed a bug that could lead to the deletion of all contents of folders with extended privileges.
Update 2008-04-09: I created an Automator workflow so that the .svn folder recovery can be started from a document's context menu in Finder.
Update 2008-04-09: I improved error handling when the document is not under version control or has been an ordinary file before.
Update 2008-02-19: I incorporated the improvements from the comments. Thank you!
Abonnieren
Posts (Atom)
