git – large file removed but still can’t push

So i have a git repo where a large file got commited by mistake:

git push origin master
Counting objects: 2480, done.
Delta compression using up to 4 threads.
Compressing objects: 100% (1922/1922), done.
Writing objects: 100% (2480/2480), 484.14 MiB | 15.10 MiB/s, done.
Total 2480 (delta 697), reused 0 (delta 0)
remote: error: GH001: Large files detected. You may want to try Git Large File Storage –
remote: error: Trace: b3405c85f13ee38933ee3ba62be554e1
remote: error: See for more information.
remote: error: File auf2/aaaaa.mp4 is 389.00 MB; this exceeds GitHub’s file size limit of 100.00 MB

I removed the file, commited bla bla and still in the commit history, the file would exist and i would get the same message over and over again.

In order to fix this, i had to remove it from the history using the command below:

git filter-branch –index-filter ‘git rm -r –cached –ignore-unmatch auf2/aaaaa.mp4’ HEAD


Leave a Reply

Your email address will not be published. Required fields are marked *

CommentLuv badge