When you work with Git in a Mac. You might notice .DS_Store file is added to your git commit unintentionally.
Remove .DS_Store File
If the DS_Store File already added to your git report. first remove the file.
find . -name "*.
DS_Store" -type f -delete
https://askubuntu.com/questions/377438/how-can-i-recursively-delete-all-files-of-a-specific-extension-in-the-current-di
Ignore .DS_Store File in your git commit
echo .DS_Store >> ~/.gitignore_global
And let git know that you want to use this file for all of your repositories:
git config --global core.excludesfile ~/.gitignore_global
Find Details here : git ignore