2014-07-23 87 views
1

我有一堆腳本想上傳到我在線創建的存儲庫中。GIT:找不到存儲庫(SSH正在運行且存儲庫拼寫正確)

我做了以下內容:

$git add 

$git commit 

$git remote add origin [email protected]:<USERNAME>/My-scripts.git **[i copied this from the website]** 

$git push 

$ git push origin master 
ERROR: Repository not found. 
fatal: The remote end hung up unexpectedly 

我檢查,以確保我有機會獲得SSH

$ssh -T [email protected] 

Hi <name>! you've successfully authenticated, . . . . 

我已經建立了我的一個GitHub的帳戶和一個我幾個電子郵件地址使用是我的主要地址。

下面是我.gihub /配置

$ cat .git/config 
[core] 
    repositoryformatversion = 0 
    filemode = true 
    bare = false 
    logallrefupdates = true 
[remote "origin"] 
    url = [email protected]:<userrname>/My-scripts.git 
    fetch = +refs/heads/*:refs/remotes/origin/* 

有什麼建議?

+1

必須有之間github.com和用戶名 –

+0

我沒有使用冒號冒號,我輸錯在上面的文章。 – GeneHunter

+0

確保原點和主控都存在。將git配置文件添加到問題('.git/config')可能有助於我們確定這一點。 –

回答

0

您確定您已經在GitHub上創建了回購?如果你加載

https://github.com/<username>/My-scripts.git 

在你的瀏覽器中,你看到回購嗎?請確保您輸入<username>/my-scripts.git.git/config中顯示的完全相同。如果你看到一個404頁面,你的repo還不存在,你需要先在GitHub上創建它。可能是一個小拼寫錯誤。

+0

謝謝。我希望這很簡單。我從github複製了地址<複製並粘貼圖標>。我甚至雙重檢查了上面的方法,並且我的回購完全按照我在配置文件中的格式拼寫。 – GeneHunter