git will track files sometimes, even if you add a file that should not be tracked in .gitignore
In this case, you must first delete the cache and then add everything.
Important: commit current changes
git rm -r --cached.
git add.
git commit -m "file tracking - changed"
source share