i've added .ds_store .gitignore file, seems ignoring .ds_store in root directory, not in every folder , subfolder.
how fix this?
i think problem you're having in earlier commit, you've accidentally added .ds_store files repository. of course, once file tracked in repository, continue tracked if matches entry in applicable .gitignore file.
you have manually remove .ds_store files added repository. can use git rm --cached .ds_store
. once removed, git should ignore it. should need following line in root .gitignore file: .ds_store
. don't forget period!
git rm --cached .ds_store
removes .ds_store
current directory. can use find . -name .ds_store -print0 | xargs -0 git rm --ignore-unmatch
remove .ds_stores
repository.
felt tip: since never want include .ds_store files, make global rule. first, make global .gitignore file somewhere, e.g. echo .ds_store >> ~/.gitignore_global
. tell git use repositories: git config --global core.excludesfile ~/.gitignore_global
.
this page helped me answer question: https://help.github.com/articles/ignoring-files