I have a git repo with say 10-20 commits. I added some files of 1gb and commited the change. I forgot to track these 1gb files using git lfs.
Now when I tried to push it to github it failed cause of the big size. Now I want git to completely forget about this change. So I made a copy of the repo and to undo the changes.
I did git reset --hard hash_value
but still the size of the .git
directory is 1gb something.
Which suggest that It knows about the change/files that were added, and still I can't push the changes.
Is there some way to tell git to completely forget about the files made in/after some specified commit (in this case the last commit made)?