Pull is not possible because you have unmerged files
Pull is not possible because you have unmerged files.
在git pull的过程中,如果有冲突,那么除了冲突的文件之外,其它的文件都会做为staged区的文件保存起来。
重现:
$ git pull
A Applications/Commerce/BookingAnalysis.java
A Applications/Commerce/ClickSummaryFormatter.java
M Applications/CommerceForecasting/forecast/Forecast.java
A Applications/CommerceForecasting/forecast/ForecastCurveProviderCategory.java
M Applications/CommerceForecasting/forecast/ForecastProvider.java
M Applications/CommerceForecasting/forecast/InputPropertyItem.java
......
A Applications/LocalezeImporter/com/tripadvisor/feeds/SingleMenuLocalezeMatcher.java
A Applications/LocalezeImporter/com/tripadvisor/feeds/TypeCategory.java
Pull is not possible because you have unmerged files.
Please, fix them up in the work tree, and then use 'git add/rm <file>'
as appropriate to mark resolution, or use 'git commit -a'.
通过git status你会发现下面古怪的事情:
zhonghua@pts/ttys000 $ git status
# On branch sns
# Your branch and 'snsconnect/sns' have diverged,
# and have 1 and 52 different commit(s) each, respectively.
#
# Changes to be committed:
#
# new file: src/config/features_daodao.ini
# new file: src/config/services.xml
# new file: src/config/svnroot/hooks/mailer.conf
# new file: src/config/svnroot/hooks/mailer.py
# new file: src/config/svnroot/hooks/post-commit
# new file: src/config/svnroot/hooks/pre-commit
# new file: src/config/svnroot/hooks/prerelease_notifications.py
# new file: src/config/svnroot/hooks/run_checks.py
…….
# Untracked files:
# (use "git add <file>..." to include in what will be committed)
#
# _build/
# css/combined/
# css/gen/
# daodao-site.patch
# daodao-site.patch1
# js/combined/
# js/gen/
# lib/weibo/
# src/bin/
Pull is not possible because you have unmerged files.
解决:
1.pull会使用git merge导致冲突,需要将冲突的文件resolve掉 git add -u, git commit之后才能成功pull.
2.如果想放弃本地的文件修改,可以使用git reset --hard FETCH_HEAD,FETCH_HEAD表示上一次成功git pull之后形成的commit点。然后git pull.
注意:
git merge会形成MERGE-HEAD(FETCH-HEAD) 。git push会形成HEAD这样的引用。HEAD代表本地最近成功push后形成的引用。
Pull is not possible because you have unmerged files的更多相关文章
- git报错:Pull is not possible because you have unmerged files解决方法
在git pull的过程中,如果有冲突,那么除了冲突的文件之外,其它的文件都会做为staged区的文件保存起来. 重现: $ git pull A Applications/Commerce/B ...
- git冲突Pull is not possible because you have unmerged files
本地的push和merge会形成MERGE-HEAD(FETCH-HEAD), HEAD(PUSH-HEAD)这样的引用.HEAD代表本地最近成功push后形成的引用.MERGE-HEAD表示成功pu ...
- git上传到版本库报错:Pull is not possible because you have unmerged files(已解决)
问题所在:操作次数太多,第一次报错之删掉了.git并没有删除下面两个文件 才报了题述错误. 解决办法: 将这三个文件都删除在重新运行所有指令.
- pod install Pull is not possible because you have unmerged files.
http://stackoverflow.com/questions/21474536/podfile-gives-an-error-on-install A bug was found in lib ...
- IDEA中使用git合并分支的过程报错:cant checkout because of unmerged files
使用idea的git插件控制代码分支合并时,由于操作不当,报错了,控制台报错如下: cant checkout because of unmerged files,you have to resolv ...
- git合并的时候,冲突问题Merging is not possible because you have unmerged files
在做项目工作的时候,同事修改了代码一个cpp代码,我同样也修改了代码,两人代码冲突了,提交之后,他代码git自动合并,并提示: [master| MERGEING]$ git merge my_new ...
- 解决git pull出现: Your local changes to the following files would be overwritten by merge: ...的问题
今天在服务器上git pull是出现以下错误: error: Your local changes to the following files would be overwritten by mer ...
- git pull 错误:The following untracked working tree files would be overwritten by merge
错误描述: $ git pull origin alphaFrom https://github.com/shirley-wu/HeartTrace * branch alpha ...
- Git pull error: Your local changes to the following files would be overwritten by merge:
联合开发,遇上的一个问题,果然,在此验证了百度的不靠谱,是谷歌出的答案...... stackoverflow上有解决方案,链接:http://stackoverflow.com/questions/ ...
随机推荐
- 洛谷P2421 [NOI2002]荒岛野人(扩展欧几里得)
题目背景 原 A-B数对(增强版)参见P1102 题目描述 克里特岛以野人群居而著称.岛上有排列成环行的M个山洞.这些山洞顺时针编号为1,2,…,M.岛上住着N个野人,一开始依次住在山洞C1,C2,… ...
- 【20190226】CSS-知识点记录::nth-child,:nth-of-type
:nth-child: ele:nth-child(k):选择父元素下第k个子元素,且该子元素为ele,若不是,则选择失败,k从1开始计数 ele:nth-child(-n+5):选中前五个子元素,n ...
- VS2017 docker部署工具的使用
**简要描述:** - VS2017的docker支持工具,支持对.Net Framework,.Net Core控制台或者Web应用,在docker中生成,调试,运行.对于.Net Framewor ...
- Flutter 动画详解(一)
本文主要介绍了动画的原理相关概念,对其他平台的动画做了一个简要的梳理,并简要的介绍了Flutter动画的一些知识. 1. 动画介绍 动画对于App来说,非常的重要.很多App,正是因为有了动画,所以才 ...
- 在插件中得到,调用 插件的id
<!DOCTYPE html><html><head lang="en"> <meta charset="UTF-8" ...
- springboot 学习之路 1(简单入门)
目录:[持续更新.....] spring 部分常用注解 spring boot 学习之路1(简单入门) spring boot 学习之路2(注解介绍) spring boot 学习之路3( 集成my ...
- Linux日志出现大量"kernel: NET: Registered protocol family 36"
一台Linux服务器的系统错误日志出现大量的" kernel: NET: Registered protocol family 36"错误信息,如下所示: Jul 2 05:27 ...
- JSF中run项目时候Tomcat8启动不了的一种方法
把另一个博客内容迁移到这 我的问题是Tomcat是可以启动的 但是run那个jsp的时候 七月 10, 2016 3:14:54 下午 org.apache.tomcat.util.digester. ...
- [20181130]control file sequential read.txt
[20181130]control file sequential read.txt --//昨天上午探究了大量控制文件读的情况,链接:http://blog.itpub.net/267265/vie ...
- f.lux 自动调节显示器色温
我的环境 f.lux 我的使用感受是让屏幕看起来舒服一些,因为我有近视,所以需要保护眼睛. f.lux官网:https://justgetflux.com/ f.lux v4.47 windows 1 ...