if you add to gitignore after files to be ignored are already indexed


git rm -r --cached tmp