當使用eclipse或者MyEclipse進行pull遠程代碼的時候,或者github的代碼的時候報如下錯誤代碼;
代表我們沒有配置我們的Git地址,這里我教大家配置一下。首先下面是錯誤代碼:
The current branch is not configured for pull
No value for key branch.master.merge found in configuration
- 1
解決方法:
-
在我們本地工程目錄找到config文件(如我的是E:\david\xiaobing.git);
-
修改config文件內容為:
[core]
repositoryformatversion = 0
filemode = false
logallrefupdates = true
[branch "master"]
remote = origin
merge = refs/heads/master
[remote "origin"]
url = https://github.com/QQ986945193/DavidAndroidProjectTools.git
(修改為自己的url,然后去掉此括號中的內容即可)
fetch = +refs/heads/*:refs/remotes/origin/*
- 1
- 2
- 最后再執行pull方法,發現工作ok了