2009-11-06 345 views
3

我的生产服务器上有一个git分支,它是centos。我试图从我的Windows机器上的TortoiseGit连接到它,但它似乎并没有工作。TortoiseGit连接到远程git仓库(不是github)

我安装了msysgit,TortoiseGit并且已经有putty。一旦安装,我在桌面上创建一个文件夹,右键单击,然后单击Git Clone ...,将远程服务器的用户名和域名放入url框([email protected]),然后在目录的桌面上的目录框。当我点击OK,它表明:

git.exe clone -v "[email protected]" "C:\.......testdir\domain.com" 
fatal: '[email protected]'does not appear to be a git repository` 
Initialized empty Git repository in C:\.......testdir\domain.com\.git\ 
fatal: The remote end hung up unexpectedly 

我只domain.com,用户名@ip地址,IP_ADDRESS domain.com/public_html/.git等诸多变种尝试,但它只是不似乎工作。

难道我做错了什么吗?

+0

它使用冒号: 非常感谢你 – Dru 2009-11-06 19:49:00

回答

1

git.exe克隆-v [email protected]:full_path_to_dot_git_directory “C:....... TESTDIR \ domain.com”

,你必须在确切地告诉git的地方centos服务器驱动git存储库存在。假设你使用ssh作为协议。

如果您更愿意使用http,则必须在服务器上配置一个Web服务器,该服务器提供.git目录并指向您在服务器配置中定义的http://domain.com/path/to/dot/git/directory

0

我怀疑你在命令中声明的路径是错误的。尝试:

git clone -v "[email protected]/full/path/to/public_html" "C:\...\testdir\domain.com" 
+0

你忘了:domain.com和完整路径之间。 – 2009-11-06 02:55:32

+0

不需要。 – 2009-11-06 03:20:11