簡體   English   中英

TortoiseGit連接到遠程git倉庫(不是github)

[英]TortoiseGit connect to remote git repo (not github)

我的生產服務器上有一個git分支,它是centos。 我試圖從我的Windows機器上的TortoiseGit連接它,但它似乎沒有工作。

我安裝了msysgit,TortoiseGit並且已經有了putty。 一旦安裝我在桌面上創建了一個文件夾,右鍵單擊,然后單擊Git Clone ...,將遠程服務器的用戶名和域名放在url框中(username@domain.com),然后將目錄放在桌面上的目錄中框。 當我單擊確定時,它顯示:

git.exe clone -v "username@domain.com" "C:\.......testdir\domain.com"
fatal: 'username@domain.com'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_address,ip_address,domain.com/public_html/.git和許多其他變種,但它似乎沒有用。

我在這里做錯了嗎?

git.exe clone -v username@domain.com:full_path_to_dot_git_directory“C:....... testdir \\ domain.com”

你必須告訴git gos存儲庫存在gos存儲庫的確切位置。 假設您使用ssh作為協議。

如果您更喜歡使用http,那么您必須在服務器上配置一個提供.git目錄的Web服務器,並指向您在自己定義的http://domain.com/path/to/dot/git/directory服務器配置。

我懷疑你在命令中說明的路徑是錯誤的。 嘗試:

git clone -v "username@domain.com/full/path/to/public_html" "C:\...\testdir\domain.com"

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM