Reputation: 5759
I have created a .gitignore file in the root directory of a project, and I would like to ignore an entire folder and anything that gets place within it.
My .gitgnore file contains only the following:
/dir/output/*
But everytime I add or modify files within the output directory the changes get tracked. Is there a way to do this?
Upvotes: 1
Views: 155
Reputation: 2570
You have to tell git to remove the cache before it starts "listening" to the new ignore. Make sure you commit your changes first and then do the following command:
git rm . -r --cached
git add .
git commit -m "what ever message"
Upvotes: 1