2011-05-05 31 views
2

在使用下面的命令初始化回購下載Android源代碼 -問題而初始化回購

repo init -u git://android.git.kernel.org/platform/manifest.git 

我收到以下錯誤 -

Traceback (most recent call last): 
File "/home/pritamn/bin/repo", line 603, in <module> 
main(sys.argv[1:]) 
File "/home/pritamn/bin/repo", line 570, in main 
_Init(args) 
File "/home/pritamn/bin/repo", line 184, in _Init 
_CheckGitVersion() 
File "/home/pritamn/bin/repo", line 213, in _CheckGitVersion 
proc = subprocess.Popen(cmd, stdout=subprocess.PIPE) 
File "/usr/lib/python2.7/subprocess.py", line 672, in __init__ 
errread, errwrite) 
File "/usr/lib/python2.7/subprocess.py", line 1201, in _execute_child 
raise child_exception 

任何人可以幫我在指出這個錯誤的確切原因?

回答

1

你必須安裝該命令才能工作的git

1

你有沒有安裝git?確保通過在命令行上鍵入「git」來安裝它。

+0

感謝您的提醒guys.But,即使安裝混帳我得到以下之後 - 從混帳 獲取回購... ://android.git.kernel.org/tools/repo.git android.git。 kernel.org [0:149.20.4.77]:errno =連接超時 android.git.kernel.org [0:149.20.20.141]:errno =連接超時 android.git.kernel.org [0:199.6。 1.176]:errno =連接超時 android.git.kernel.org [0:130.239.17.12]:errno =連接超時 致命:無法連接套接字(連接超時) 它是否表明我的問題網絡連接或git服務器? – Wrangler 2011-05-05 12:30:20

+0

用「http://」代替「git://」的確有竅門。 謝謝你們.. – Wrangler 2011-05-05 12:54:39

1

在Win7 64bit上運行我必須在我的PATH中添加「C:\ Program Files(x86)\ Git \ bin」才能使其工作。

0

我曾遇到過這種情況,您需要apt-get remove git-core並使用apt-get install git-core重新安裝。