kristofer ревизій цього gist . До ревизії
1 file changed, 1 insertion, 1 deletion
note.md
@@ -1,6 +1,6 @@ | |||
1 | 1 | ### For re-doing the repo, to take into account your changes to the `.gitignore` | |
2 | 2 | ||
3 | - | Remove Stuff that should ignored. | |
3 | + | Remove Stuff that should ignored. (like class files (java) or .pyc files (python)) Don't Store node_modules either! | |
4 | 4 | ||
5 | 5 | The series of commands below will remove all of the items from the Git Index (not from the working directory or local repo), and then updates the Git Index, while respecting git ignores. PS. Index = Cache | |
6 | 6 |
kristofer ревизій цього gist . До ревизії
1 file changed, 19 insertions
note.md(файл створено)
@@ -0,0 +1,19 @@ | |||
1 | + | ### For re-doing the repo, to take into account your changes to the `.gitignore` | |
2 | + | ||
3 | + | Remove Stuff that should ignored. | |
4 | + | ||
5 | + | The series of commands below will remove all of the items from the Git Index (not from the working directory or local repo), and then updates the Git Index, while respecting git ignores. PS. Index = Cache | |
6 | + | ||
7 | + | First: | |
8 | + | ||
9 | + | ``` | |
10 | + | git rm -r --cached . | |
11 | + | git add . | |
12 | + | ``` | |
13 | + | ||
14 | + | ||
15 | + | Then: | |
16 | + | ``` | |
17 | + | git commit -m "Remove ignored files" | |
18 | + | ``` | |
19 | + |