【发布时间】:2012-11-10 15:36:42
【问题描述】:
我正在尝试使用 http://danielmiessler.com/study/git/#website 设置 git 来管理我的网站。
我已经到了说明的最后一步:git push website +master:refs/heads/master
我在 win7 中使用 git ming32 命令行工作
$ git push website +master:refs/heads/master
Bill@***.com's password:
Connection closed by 198.91.80.3
fatal: Could not read from remote repository.
Please make sure you have the correct access rights
and the repository exists.
这里的一个问题可能是程序正在寻找 Bill@***.com。当我通过 ssh 连接到我的网站时,我有一个不同的用户名(比如说“abc”)。所以也许这应该是 abc@***.com。如果是这样,我不知道如何更改它,或者我是否可以使用别名进行推送
【问题讨论】:
-
我遇到了同样的问题,有时当 git 服务器无法访问或出现“内部服务器错误”之类的情况时会发生此错误。
-
首先请查看
.git/config文件,看看一切正常。它对我来说有错误的 set-url 和 origin 值。 -
你能告诉我 .git/config 和 .ssh/config 的正确顺序吗...因为我有点困惑。
标签: git