我有一个非常奇怪的问题与git和github。当我试着推的时候,我得到:
git push -u origin master
ERROR: Repository not found.
fatal: The remote end hung up unexpectedly
我添加了遥控器:
git remote add origin git@github.com:account-name/repo-name.git
什么好主意吗?
我有一个非常奇怪的问题与git和github。当我试着推的时候,我得到:
git push -u origin master
ERROR: Repository not found.
fatal: The remote end hung up unexpectedly
我添加了遥控器:
git remote add origin git@github.com:account-name/repo-name.git
什么好主意吗?
当前回答
我需要杀死凭证帮助进程(有多个),它在再次提供凭证后解决了这个问题。
killall git-credential-cache——守护进程
其他回答
这也可能发生,因为GitHub本身宕机了。一定要检查stat.github.com,看看问题是否在他们那边。
2018年10月22日,你有好几个小时都无法推送到GitHub。
为了解决这个问题(在Linux上),我只需要运行这个:
git config --global --unset credential.helper
使用Ubuntu时,我总是需要使用SSH而不是HTTPS添加远程
git remote add origin git@github.com:username/project.git
而不是
git remote add origin https://github.com/username/project.git
只需使用SSH远程url,而不是HTTPS
我也有同样的问题。
我解决了把我的gitlab用户名前缀到gitlab.com url的问题,就像这样: 之前: https://gitlab.com/my_gitlab_user/myrepo.git 后: https://my_gitlab_user@gitlab.com/my_gitlab_user/myrepo.git 在这种情况下,将再次要求凭据,这就完成了!