Using git for a project, I accidentally added to a commit a big .zip
file. I didn't notice until I started uploading it to github. When I noticed, I hit ctrl-c
, git remove
, git commit
and uploaded it again (now with the file untracked).
I know that this wasn't the right choice to do, because once I committed the .zip
, it stays in the repo until I revert the commit, but sadly I didn't.
Now, when someone tries to download from the repo, it takes a lot of time to do it, sometimes yields git the remote end hung up unexpectedly
(which I've read can be solved by doing some git config
) and is very annoying.
My point is: is there a way to tell further pull/fetch request that forget this specific file in this specific commit version?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…