Git ignore file for Xcode 4 projects
Here are git ignore files for basicly every language including Xcode : Github - git ignore
For me it is working like a charm. Here is the content of the Objective-C.gitignore
# Xcodebuild/**.pbxuser!default.pbxuser*.mode1v3!default.mode1v3*.mode2v3!default.mode2v3*.perspectivev3!default.perspectivev3*.xcworkspace!default.xcworkspacexcuserdataprofile*.moved-asideDerivedData
Existing answers are good. I just want to leave a note for people who are using CocoaPods
to manage libraries. Besides the xcworkspace
generated by CocoaPods, you should also ignore Pods/
directory:
Pods/*
every developer should do pod install
on their own machine separately. otherwise, they may face many environment issues.