简体   繁体   English

.vs-code server/bin 和 tabnine 扩展试图推送到 GitHub,失败

[英].vs-code server/bin and tabnine extension trying to push to GitHub, failing

I'm trying to push my code to GitHub, but keep getting the following errors:我试图将我的代码推送到 GitHub,但不断收到以下错误:

remote: warning: File .vscode-server/bin/e4503b30fc78200f846c62cf8091b76ff5547662/node is 75.64 MB; this is larger than GitHub's recommended maximum file size of 50.00 MB
remote: error: Trace: 0d8800fdb9c63ca4691425c2af625642fe616e4fc3de1320cdb47e20a5fc07bf
remote: error: See http://git.io/iEPt8g for more information.
remote: error: File .local/share/TabNine/models/ce94127b.tabninemodel is 241.05 MB; this exceeds GitHub's file size limit of 100.00 MB
remote: error: GH001: Large files detected. You may want to try Git Large File Storage - https://git-lfs.github.com.
To https://github.com/elilogbro/p-rails.git
 ! [remote rejected]   main -> main (pre-receive hook declined)
error: failed to push some refs to 'https://github.com/elilogbro/p-rails.git'

I don't think the Tabnine extension nor the.vscode-sever file should be getting to pushed to GitHub and I've never encountered these errors on other projects I've done.我不认为 Tabnine 扩展和 .vscode-sever 文件应该被推送到 GitHub,而且我在我完成的其他项目中从未遇到过这些错误。 Should I somehow add these files to.gitignore, or is there another way to prevent them from being included in the push?我应该以某种方式将这些文件添加到 .gitignore,还是有其他方法可以防止它们被包含在推送中?

Thanks everyone!感谢大家!

After a week of dealing with this issue, I found out that I had accidentally git init a level above my repo, so my entire directory was trying to push to GitHub.在处理这个问题一周后,我发现我不小心在我的 repo 之上进行了git init ,所以我的整个目录都试图推送到 GitHub。 To fix the issue, in my directory i git remote remove origin , then cd'd into my project folder, git init, git add., git commit -m, and git push -u origin main .要解决此问题,我在我的目录中执行git remote remove origin ,然后将git init, git add., git commit -m, and git push -u origin main CD 到我的项目文件夹中。

I don't think the Tabnine extension nor the.vscode-sever file should be getting to pushed to GitHub我不认为 Tabnine 扩展和 .vscode-sever 文件应该被推送到 GitHub

Then use git filter-repo (Python-based, must be installed first) to remove from your local repository history those folders (and their content) .然后使用git filter-repo (基于 Python,必须首先 安装从本地存储库历史记录中删除这些文件夹(及其内容)

Only once those folder and large content are no longer part of your local repository commits would you be able to push.只有当这些文件夹和大内容不再是本地存储库提交的一部分时,您才能推送。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 样式化的组件扩展不适用于 Vs 代码的新更新 - styled components extension is not Working in new update of Vs-code 在哪里获取 azure 应用程序服务 VS 代码扩展的部署日志 - where to get deployment logs of azure app service VS-Code extension 如何在 VS-Code 中关闭或关闭调试模式 - How to turn off or close debugging mode in VS-Code 使用 Flow.js 做出反应的自定义按钮组件在 vs-code 中的自动完成 - Auto-Complete in vs-code for custom button component in react using Flow.js Create-react-app 从终端启动,但不是 vs-code - Create-react-app fires up from terminal but not vs-code VS-code 在包含连字符的 class 名称之间添加空格 - VS-code adding spaces between class name which contains hyphens 带有js扩展的React文件的GitHub代码突出显示 - GitHub Code highlighting for React file with js extension vs-code中的人如何在现有终端上运行任何命令而不添加新终端我可以在这里使用什么快捷键? - Guys in vs-code how can i run any command on existing terminal without adding new terminal what shortcut-key i can use here? 有人可以帮我将代码推送到我的 github 存储库吗? - Can someone help me push code to my github repo? Gatsby部署到Github失败 - Gatsby Deployment to Github Failing
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM