git Please move or remove them before you can merge. 错误解决方案

来源:互联网 发布:玻璃胶 白色透明知乎 编辑:程序博客网 时间:2024/04/30 21:08


git pull 时 往往会遇到各种各样的问题 ,下面是常遇到的一种状况



Updating 7c9e086..936acac
error: The following untracked working tree files would be overwritten by merge:
Common/HFHttpRequest/HFHttpRequestParameters.h
Common/HFHttpRequest/HFHttpRequestParameters.m


Please move or remove them before you can merge.

Aborting


解决方案 其实很简单

:

git clean  -d  -fx ""
其中 
x  -----删除忽略文件已经对git来说不识别的文件
d  -----删除未被添加到git的路径中的文件
f  -----强制运行

原创粉丝点击