2013-07-04 53 views
2

我按照下面的步驟來設置Git服務器:https://github.com/msysgit/msysgit/wiki/Setting-up-a-Git-server-on-Windows-using-Git-for-Windows-and-CopSSH,一切工作正常,直到我克隆的最後一步服務器存儲庫。用CopSSH在Windows上設置Git服務器,但得到這個錯誤:似乎不是一個Git倉庫

在建立的過程中,我記錄了一些其他的錯誤,但都解決了。它們是:

  1. 文件libiconv-2.dll未發現:從git/bin複製文件libiconv-2.dllICW/Bin
  2. 文件git-receive-pack.exe未發現:在ICW/Bin創建3軟鏈接git-receive-pack.exegit-upload-pack.exegit-upload-archive.exe,源文件是git/libexec/git-core/*

在從服務器克隆庫的最後一步,我得到這個錯誤:

我得到這個錯誤:

$ git clone [email protected]:/cygdrive/d/GitRepo/Test.git 
Cloning into 'Test'... 
fatal: '/cygdrive/d/GitRepo/Test.git' does not appear to be a git repository 
fatal: Could not read from remote repository. 

Please make sure you have the correct access rights 
and the repository exists. 

任何一個可以幫助?謝謝。

回答

4

我相信本教程旨在從msysgit(作爲in heregit bash session工作。
不在cygwin會話中(並解釋您的dll問題或軟鏈接創作)。

的最後一步是:

git clone {username}@{servername}:{repodriveletter}:/{repopath} 

這表明像這樣的命令:

git clone [email protected]:/D/GitRepo/Test.git 
# or, as the OP found out: 
git clone [email protected]:d:/GitRepo/Test.git 

我會建議not using cygwin(如explained here),並使用msysgit代替。

+0

'git clone [email protected]:/ D/GitRepo/Test.git'仍然無法正常工作。但是這是工作的:'git clone [email protected]:d:/ GitRepo/Test.git'。謝謝! –

+0

@AlbertZhang優秀。我在答案中增加了這個語法以提高可見性。你還使用cygwin的git嗎? – VonC

+0

我有點迷失在「會議」中。 「會話」是否意味着一個shell?我記得CopSSH的配置是在Unix Shell中從CopSSH(_Start Menu> Copssh> 03.啓動一個Unix BASH Shell_)完成的。並創建存儲庫,測試克隆是在git bash(_Start Menu> Git> Git Bash_)中完成的。 –

相關問題