版权声明:本文为博主原创文章,遵循 CC 4.0 BY-SA 版权协议,转载请附上原文出处链接和本声明。
1.从本地仓库中移除过大文件
github push文件过大,error: GH001: Large files detected. this exceeds GitHub's file size limit of 100 MB
#Stage our giant file for removal, but leave it on disk
git rm --cached giant_file
# Amend the previous commit with your change
#Simply making a new commit won't work, as you need
#to remove the file from the unpushed history as well
git commit --amend -CHEAD
#Push our rewritten, smaller commit
git remote add origin git@github.com:yy2536298120/MXNet-Demo.git
#将本地仓库项目更新提交到GitHub仓库项目中
git push -u origin master
- 1
- 2
- 3
- 4
- 5
- 6
- 7
- 8
- 9
- 10
2.添加1步骤误删除的小于100M的文件
#执行添加:cd到本项目需要添加的文件目录下
git add file_name.xxx
#提交注释
git commit -m "add commit"
#将本地仓库项目更新提交到GitHub仓库项目中
git push -u origin master
- 1
- 2
- 3
- 4
- 5
- 6