git过大超容量后怎么办?

git 提交了大文件,lfs 也没用了,显示

```
batch response: This repository is over its data quota. Account responsible for LFS bandwidth should purchase more data packs to restore access.
error: 推送一些引用到 **********:shiwanghua/ANN_VECTOR_RETRIEVAL.git' 失败
```

这时可以:

1. 用 `git reset --soft HEAD^` 撤回一次或多次 commit,修改的文件内容不会被撤销

2. 修改 .gitignore 文件,把某些不必要的大文件的相对路径加进去,表示不上传这些文件到github

3. 响应 .gitignore 的修改:git rm -r --cached .; git add .; git commit -m 'update .gitignore '

然后就可以 git push 了
全部评论
这样也可以啊
点赞 回复 分享
发布于 2023-03-28 18:27 湖北

相关推荐

点赞 评论 收藏
分享
爱吃烤肠的牛油最喜欢...:50K是ssp了估计,ssp的人家多厉害都不用说,每年比例大概在百分之5左右
点赞 评论 收藏
分享
评论
3
1
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务