這裏是我做的,到目前爲止(在SourceTree):
如何使用SourceTree創建新的git存儲庫?
- 選擇「新建庫」
- 選擇目標路徑(「你好」)
- 在「喂」創建一個文件目錄
- 提交該文件(它創建一個本地主分支)
- 創建新的遠程(SSH://[email protected]:22/SRV/GIT中/喂)
- 推到遠程分支
現在,我得到一個錯誤:
git -c diff.mnemonicprefix=false -c core.quotepath=false push -v --tags --set-upstream origin master:master
Pushing to ssh://[email protected]:22/srv/git/hallo
fatal: '/srv/git/hallo' does not appear to be a git repository
fatal: Could not read from remote repository.
我與其他存放區的十幾個工作,而不該服務器上的任何困難。所以它不能成爲訪問或ssh問題。我也加倍檢查了服務器的IP地址。
如果我啓動終端並寫上 「混帳遠程-v」 我得到:
origin ssh://[email protected]:22/srv/git/hallo (fetch)
origin ssh://[email protected]:22/srv/git/hallo (push)
如果我試圖把( 「混帳推起源大師」)我得到:
fatal: '/srv/git/hallo' does not appear to be a git repository
fatal: Could not read from remote repository.
請確保您擁有正確的訪問權限 並存在存儲庫。
我不知道我錯過了什麼。 你能幫忙嗎?
你創建一個SSH服務器上的一個新的回購? – VonC
嘗試將git文件夾更改爲另一個文件夾,您的錯誤可能是由寫入權限引起的。 –
@VonC:不,我沒有。我一定要嗎?我認爲推動提交會爲我做到這一點。這是錯的嗎? –