Here's my situation, and it's probably fairly common but I have yet to find a satisfactory way to do it.
I am developing an iPhone application that will have a read-only, pre-loaded Core Data database stored in the app's bundle. I completely understand how to deploy such a thing. That isn't my problem.
My problem is How do I pre-load the Core Data database as a part of my build process? I can imagine several ways to do this, but I'm looking for a solution that integrates best with Xcode and has the least amount of hackery.
So far, my #1 choice is to create a project for a command-line tool that shares the Core Data Model with the iPhone project. This tool could then be run as a part of a shell script phase of the iPhone project's build process. What sucks is that, because one is an iPhone project and the other an OS X command-line tool, they cannot share the same project or even be referenced from one to the other. They must be completely separate. :(
Any suggestions?