What Xcode Files Should Git Track and Ignore?
When you start using version control in your Xcode projects, you may become confused about which files git should track and which files git should ignore. This confusion is normal. Xcode projects contain much more than your Swift files, and some of these extra files are basically unreadable. What files in your project should you tell git to ignore?
Fortunately the site gitignore.io has solved this problem for you. Go to gitignore.io, enter Xcode in the search field, and click the Create button. You will get a git ignore file with a list of file types that git should ignore. Add the git ignore file to your project folder.
Need More Information on Using Git with Xcode?
Check out my version control book. It has an entire chapter on ignoring files, including what to do when git starts tracking an unwanted file.