views:

46

answers:

1

Initially, I've just been sticking with the default generated application structure of my Cocoa app:

  • /Classes for all source files (.m and .h)
  • /Resources for Nibs and other obvious resources

However, as my application is growing, I'm finding that it's less organized then I'd like in the Classes folder with everything at the root level. Without namespacing, it seems the Java organization scheme is out of the question, so I'm leaning towards the Rails scheme of organizing the files in models, views and controllers subdirectories. Before I did this though, I wanted to get feedback on whether there was a more Cocoa-idiomatic way of organizing the source tree, or whether there were any implications I should be aware of when doing this. How do you guys organize your source files in a Cocoa app?

A: 

See http://cocoawithlove.com/2010/06/design-of-every-mac-application.html

It doesn't go into the nuts and bolts of what folders to create and where to put them, but it will give you a better idea of how to organize things (in your head, if not necessarily on disk).

Kristopher Johnson
Thanks, that was a great read. It definitely gives some insight on how to break things down in my head, but it still leaves me wondering if there's a best practice in terms of organizing source in a folder hierarchy. Thanks for passing along the link.
Lytol