我之前有一個static/a.bin文件,比較大。但我後來刪除了它,cached中也不見了,但是我push時,還是有它。提示如下:
remote: warning: File static/a.bin is 95.37 MB; this is larger than Git@OSC's recommended maximum file size of 50 MB remote: error: File static/a.bin is 442.09 MB; this exceeds Git@OSC's file size limit of 100 MB remote: error: hook declined to update refs/heads/master
找到答案了,不好意思。執行了git filter-branch --index-filter 'git rm -r --cached --ignore-unmatch static/a.bin' HEAD 就行了