gitignoring Tracked Files

This post is more for me than for anyone else. I keep finding myself forgetting to add something to my .gitignore, and I have to search for the solution all over again. So, here’s how to fix it:

git rm -r --cached .

Then, just re-commit it all. Simple as that! And for the record, I got this solution from this Stack Overflow.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s