添加一个视频文件想存档,但git规定大小不得超过100M,但回退历史也不知怎么清除那次提交。
Github的错误提示(毫无意义)
Enumerating objects: 15, done. Counting objects: 100% (15/15), done. Delta compression using up to 8 threads Compressing objects: 100% (11/11), done. Writing objects: 100% (11/11), 108.26 MiB | 54.00 KiB/s, done. Total 11 (delta 4), reused 0 (delta 0), pack-reused 0 remote: Resolving deltas: 100% (4/4), completed with 3 local objects. remote: error: GH001: Large files detected. You may want to try Git Large File Storage - https://git-lfs.github.com. remote: error: Trace: b0b7757baa9210451f59386095a08234d86dbab640c6243a01f65617b019f588 remote: error: See http://git.io/iEPt8g for more information. remote: error: File video.mov is 116.46 MB; this exceeds GitHub‘s file size limit of 100.00 MB To https://github.com/weidongz/report.git ! [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to ‘https://github.com/weidongz/report.git‘
Gitee的错误提示
Enumerating objects: 9, done. Counting objects: 100% (9/9), done. Delta compression using up to 8 threads Compressing objects: 100% (6/6), done. Writing objects: 100% (6/6), 105.60 MiB | 1.34 MiB/s, done. Total 6 (delta 3), reused 0 (delta 0), pack-reused 0 remote: Powered by GITEE.COM [GNK-5.0] remote: error: File: 46aec9f0a3c465d2e023f626f4cad4eba09f9122 106.16 MB, exceeds 100.00 MB. remote: Use command below to see the filename: remote: git rev-list --objects --all | grep 46aec9f0a3c465d2e023f626f4cad4eba09f9122 remote: Please remove the file from history and try again. (https://gitee.com/help/articles/4232) To gitee.com:weidongzheng/reports.git ! [remote rejected] master -> master (pre-receive hook declined) error: failed to push some refs to ‘gitee.com:weidongzheng/reports.git‘
注意它给了网址
https://gitee.com/help/articles/4232
访问该网址照着做即可
原文:https://www.cnblogs.com/WindyZ/p/14056038.html