These files are automatically generated by Xcode and maintain information regarding source control. Xcode is typically used in Objective-C and Swift projects, so add these to the ignored files for these platforms.
some details based on #1221
I just copied Objective-C.gitignore. It seemed to do the job with a small Swift project.