Rewrite history. Use git rebase to squash all commits between adding and removing the blobs. Its gross, and if your project is publically used you need to tell everyone what your doing and why.
post
replies:
In the past I've used this: https://rtyley.github.io/bfg-repo-cleaner/
So git tracks the history of your commits and gives you the ability to restore your project to any exact commit. For text files that is efficiently accomplished by only tracking the delta between text on each commit. For binaries, git can only compare file hashes and if the file changes the whole file is uploaded again in full to your history. You probably changed a few 1mb images a bunch of times and now have every copy of it in your git history. Git LFS solves this problem. You can pull the problematic files out with a tool that rewrites history, but rewriting history is usually not great idea, there are too many footguns.
all 7 comments