Created
February 5, 2023 21:11
-
-
Save krassdanke/6ba5b8f9890d6fc639c3d9780aa9ced1 to your computer and use it in GitHub Desktop.
git-eradicate (for video/parasite.avi)
This file contains hidden or 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
# All credits goes to "Vi." @ stackoverflow | |
# https://stackoverflow.com/questions/1029969/why-is-my-git-repository-so-big | |
git filter-branch -f --index-filter \ | |
'git rm --force --cached --ignore-unmatch video/parasite-intro.avi' \ | |
-- --all | |
rm -Rf .git/refs/original && \ | |
git reflog expire --expire=now --all && \ | |
git gc --aggressive && \ | |
git prune |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment