@Dima mentioned that NIB files are hard to merge, this also applies to project files. Some ways to deal with this:
- Lay out the whole file and class structure ahead of time
- Have a single member of the team who is responsible for maintaining project structure, and if anyone wants to add/move/rename a file they get the "project master" to do it
- Divide the app up into a series of different static library projects, and assign one person to each
Using static libraries is one of those things that is much much harder than it should be, but once you figure out the right combination of obscure changes to XCode's build settings everything works well.
In a nutshell, you need to
- In the static library set "skip install" to
YES
, and make all header files public
- In any projects using the library link it in in "build phases" and add a header search path so it knows where to look for the header files.
See the following links for the step by step:
You could also use a dependency management system like CocoaPods to automate some of this static library configuration and build. See here.
Finally, this answer also has an interesting approach to avoiding xcproject
conflicts: instruct git to "always union" the merge. Haven't tried this myself.