I've read ti in stackoverflow:
E.g. to remove all *.gz files accidentally committed into git repository:
du -sh .git #==> e.g. 100M
git filter-branch --index-filter 'git rm --cached --ignore-unmatch *.gz' HEAD
git push origin master --force
rm -rf .git/refs/original/
git reflog expire --expire=now --all
git gc --prune=now
git gc --aggressive --prune=nowBlog categories: Programming
Add new comment