I find the default name "MyDocument" that Xcode uses for new document-based Cocoa apps to be annoying, sounding more appropriate for Fisher-Price toys than professional software. Renaming all of the moving pieces in Xcode can be a bit daunting, and I don't want to edit the project template, since those tend to get revised as time goes on. This is what I do:
- make the new project
- replace MyDocument with the newDocument name (BWGraphDocument here):
perl -pi -e 's/MyDocument/BWGraphDocument/g' *.[hm] *.xcodeproj/* *.plist
- rename the document files:
mv MyDocument.h BWGraphDocument.h
mv MyDocument.m BWGraphDocument.m- rename the nib file:
mv MyDocument.nib BWGraphDocument.nib
- open the nib file, drag in your document header and change the class of the File's Owner to the new class. Delete the MyDocument type.