Why Sometimes Git Ignore Doesn’t Work

Sometimes the files you’re trying to ignore┬áhad already been submitted into version control on previous occasions. To ignore those existing files, you’ll need to re-submit them as deleted files. After which they would be┬áremoved from the repository. It looks like .gitignore isn’t working, but it actually is.