您的位置:首页 > 编程语言

[Github] fatal: remote error: You can't push to git 解决办法

2013-06-03 17:32 447 查看
branch正确的情况下, 不知为什么,在push的时候总是出现:

fatal: remote error:
You can't push to git://github.com/user_name/user_repo.git
Use git@github.com:user_name/user_repo.git
的提示, 解决办法:

$ git remote rm origin
$ git remote add origin git@github.com:user_name/user_repo.git
$ git push origin


ok!

经过高人的点播,找到了原因:
如果在git clone的时候用的是

git://github.com:xx/xxx.git

的形式, 那么就会出现这个问题,因为这个protocol是不支持push的



$git clone git@github.com:username/myNCCL.git
就可以用git push了。
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐