Created
February 20, 2015 18:51
-
-
Save mpukit/d845d79b60c84509c1d9 to your computer and use it in GitHub Desktop.
Fix .gitignore so that it untracks every file that is newly placed in your .gitignore file
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1) To untrack a single file that has already been added to your repo (to stop tracking the file but not delete it from your system, use: | |
git rm --cached <filename> | |
2) To untrack every file that is now in your .gitignore - commit changes, then: | |
git rm -r --cached . | |
This removes any changed files from the index (staging area). Then: | |
git add . | |
Commit all: | |
git commit -m ".gitignore is now working correctly" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
But where do I put this commands???