【发布时间】:2010-11-03 04:58:22
【问题描述】:
尝试使用git clone 命令。我的理解(如果有错误请更正)是,为了托管 Git 存储库,您只需要一台运行 ssh 的机器,并且项目/存储库位于允许的位置。
我的 git 存储库位于运行 ssh 的 OS X 系统上。我正在尝试在 Windows XP 系统上克隆它。我在 XP 机器上安装了 Git Bash。在 Git bash (MINGW) 控制台中,我可以 ssh 进入 Mac 没问题。
但是,git clone 失败了...
$ git clone username@host:~/project/path/contactdb
Initialized empty Git repository in
c:/Documents and Settings/Administrator/My Documents/projects/contactdb/.git/
bash: git-upload-pack: command not found
fatal: The remote end hung up unexpectedly
尝试使用和不使用.git 扩展:
$ git clone username@host:~/project/path/contactdb
$ git clone username@host:~/project/path/contactdb.git
我需要在 Mac 上安装其他东西吗?
【问题讨论】:
-
只有在远程目录名称附加
.git时,您才需要尝试使用.git扩展。 -
谢谢,我想知道。
-
如果您通过 ssh 连接,请使用:git clone ssh://user@host/~/project/path/contactdb
-
并且...确保您可以使用
ssh user@host与 ssh 连接 -
Ethan 目前通过 SSH 连接的方式是正确的。
标签: git