2012-04-29 58 views
0

這裏是我使用的Heroku開發一個應用程序,我使用github上與它一起爲一個項目我的問題Github上和Heroku的克隆錯誤 - 無效的路徑/語法錯誤

現在,當我嘗試和使用github上(克隆),而Heroku的對不同的項目,它說工作...

[email protected]:~$ 
[email protected]:~$ 
[email protected]:~$ git init 
Initialized empty Git repository in /home/michael/.git/ 
[email protected]:~$ ls 
Desktop Downloads   gifiniti  Music  Pictures Templates Ubuntu One 
Documents examples.desktop gifinitiApr24 oldgifiniti Public tmp  Videos 
[email protected]:~$ git clone [email protected]:toadiferus/SecretTunnel 
Cloning into SecretTunnel... 

! Invalid path. 
! Syntax is: [email protected]:<app>.git where <app> is your app's name. 

fatal: The remote end hung up unexpectedly 
[email protected]:~$ 

我將如何解決這個問題?在這個特定的問題上找不到任何支持。 如何更改命令的語法?我想從github克隆一個項目,而不是heroku。

謝謝!

  • 邁克爾

回答

0

首先,在克隆之前,您不需要init-init用於將項目文件夾轉換爲git存儲庫,除非您真的打算將整個用戶目錄轉換爲git repo?我建議你刪除將從你這樣做創建的.git文件夾。

爲了確保您使用的是正確的路徑,請轉到github上的項目,並使用看起來像剪貼板的圖標將正確的URL複製到剪貼板,粘貼到命令行並查看會發生什麼。

我也想不明白,爲什麼當你做一個

​​

你會得到什麼看起來像Heroku的推錯誤???從github URL中的Git克隆應該簡單地將項目從github克隆到本地機器上。

! Invalid path. 
! Syntax is: [email protected]:<app>.git where <app> is your app's name. 

你在編輯你正在粘貼的輸出嗎?

0

的git的URL應該git的上月底,即。 [email protected]:toadiferus/SecretTunnel.git

+0

我試過,但我最終得到了相同的錯誤 – michaelghinrichs 2012-04-29 05:56:57

+0

'git clone [email protected]:toadiferus/SecretTunnel.git'在這裏工作完美。 – sevenseacat 2012-04-29 05:58:48

+0

所以你在你的電腦上試過它,它工作?好了,這有助於我更好地瞭解問題的來源,謝謝! – michaelghinrichs 2012-04-29 06:05:54

1

如果您使用了heroku帳戶插件,您的〜/ .ssh/config可能已被劫持。同樣的事情發生在我身上。我刪除了我的SSH配置的內容,一切都很好!

+1

對於可能劫持他們賬戶的任何東西(如果你是被____劫持的),你似乎都錯過了這個詞。需要這些信息才能找到根本原因。 – 2012-10-29 21:39:11