I have created a .gitignore file in the folder with the .git folder,
but I still get the files I'm trying to ignore when doing a rescan of the repository.
This is the content of the file.
# Ignored files
You need to make sure the file you are still seeing are not currently committed or staged.
If you remove them (
git rm or
git rm --cached), and then add them as private file, then they will be ignored.