Hi Matt

> After using this technique, I did have one more question related to automated 
> class generation.  Xcode automatically tried to add the class files to the 
> AppName.xcdatamodeld directory.  My initial assumption was that this was only 
> because I had it selected in the source list when I attempted to add the 
> class files, so I selected a new destination of the Classes folder where all 
> other classes are stored.

When you use the File|New File…|Managed Object Class route to create classes 
you get a dialog that asks you where to save the generated files. This usually 
defaults to saving the files, on disk, to the main project directory, but 
putting the files in the "virtual" Models folder in the project manager.

Personally, I tend to start every project by creating my own, preferred, folder 
hierarchy on disk, then changing the project manager folders to point to those 
folders.

Although you can, in theory, leave all the files, on disk, in the main project 
folder and simply work with project folders, which are only really logical 
groupings, I tend to use the following folder structure on disk (others may do 
it differently):

ProjectName
  Models
  Classes
  Resources
    English.lproj
    French.lproj
    …

I then move the files, generated when the project was created, to those 
directories, except for the ProjectName-Info.plist and ProjectName_Prefix.pch 
files, which I leave in the root directory.

This will cause the files and folders to turn a delicate shade of red :-) First 
of all, select the Models folder, press Cmd-I and change the path of the 
project folder to point to that on disk. Then do the same to the other folders 
and files until the project knows where to find everything.

Needless to say, there is more than one way to tackle this folder management 
and others may have their own opinions.

Joanna

--
Joanna Carter
Carter Consulting

_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to arch...@mail-archive.com

Reply via email to