Untrack files already pushed to git repository

This week, I pushed a file to a git repository which later on I realized would be better if the file is not tracked anymore. The file was the coverage/index.html generated by simplecov gem for my team’s Rails project. Everytime the unit tests are run in our local machine, this file gets updated. There’s no harm in pushing this kind of file but when doing pull requests, I just feel like this adds to the noise.

Adding a tracked file to .gitignore will not automatically remove it from being tracked. Here’s what I did to untrack it.

Read More