git - How to remove remote repos's directory after I add this directory into .gitignore? -
in beginning, dont put logs/
.gitignore, after git push
, logs/
appears in remote, add logs/
in .gitignore , commit , push, logs/
still remains in remote, how remove logs/
in remote ?
.gitignore
ignores untracked files, once files added repo, tracked until explicitly removed.
if don't care keep directory in history, need remove git git rm -r logs
, git commit
. however, if directory large , increases repository size, follow advice yan zax filter-branch
.