本文转自:http://yijiebuyi.com/blog/5b55eb51ad49ce41e2de9c85dd4513ca.html

今天获取git线上仓库代码报了这个错误:

zhangzhi@moke:~/code/ktsg-api$ git pull
You have not concluded your merge (MERGE_HEAD exists).
Please, commit your changes before you can merge.

错误可能是因为在你以前pull下来的代码没有自动合并导致的.

有2个解决办法:

1.保留你本地的修改

git merge --abort

git reset --merge

合并后记得一定要提交这个本地的合并

然后在获取线上仓库

git pull

2.down下线上代码版本,抛弃本地的修改

不建议这样做,但是如果你本地修改不大,或者自己有一份备份留存,可以直接用线上最新版本覆盖到本地

git fetch --all

git reset --hard origin/master

git fetch

当然还有一个最笨的方法,就是重新clone一份代码,抛弃这个工作目录,哈哈,开玩笑.

转载于:https://www.cnblogs.com/520playboy/p/7552442.html

You have not concluded your merge (MERGE_HEAD exists) git拉取失败相关推荐

  1. git:Git fetch和git pull的区别, 解决Git报错:error: You have not concluded your merge (MERGE_HEAD exists)....

    Git fetch和git pull的区别, 解决Git报错:error: You have not concluded your merge (MERGE_HEAD exists). 解决办法一:保 ...

  2. You have not concluded your merge (MERGE_HEAD exists)

    Git提交报错:error:You have not concluded your merge (MERGE_HEAD exists) 原因:pull下来的以前代码自动合并失败 解决 方法一:保留本地 ...

  3. git pull指令报错:error: You have not concluded your merge (MERGE_HEAD exists).

    使用git pull 指令时报错:error: You have not concluded your merge (MERGE_HEAD exists). 直接翻译上面的报错信息可知: 错误:您尚未 ...

  4. Git常用命令、及常见报错处理:You have not concluded your merge (MERGE_HEAD exists)

    一.常用命令 切换到master分支:git checkout master 查看已有本地及远程分支:git branch -a(先git pull拉下全部数据) 查看远程分支:git branch ...

  5. 解决Git报错:error: You have not concluded your merge (MERGE_HEAD exists).

    Git 解决Git报错:error: You have not concluded your merge (MERGE_HEAD exists). 开发新业务,拉取代码时,路由文件发生冲突,解决此文件 ...

  6. 解决Git报错:error: You have not concluded your merge (MERGE_HEAD exists)

    Git fetch和git pull的区别: 都可以从远程获取最新版本到本地 1.Git fetch:只是从远程获取最新版本到本地,不会merge(合并) $:git fetch origin mas ...

  7. git拉取报错:You have not concluded your merge. (MERGE_HEAD exists)

    You have not concluded your merge. (MERGE_HEAD exists) 原因 一般出现这种情况是没有完成上次的merge操作,就进行了pull操作,就会报这种错误 ...

  8. 【GitHub报错】You have not concluded your merge (MERGE_HEAD exists).解决方法

    git push出现错误: You have not concluded your merge (MERGE_HEAD exists). 原因可能是在以前pull下来的代码自动合并失败. 方法一:保留 ...

  9. 【git】You have not concluded your merge (MERGE_HEAD exists).

    error: You have not concluded your merge (MERGE_HEAD exists). 原因:pull下来的代码没有自动合并导致的.或是在以前pull下来的代码自动 ...

最新文章

  1. 基于VTK与Qt的体绘制程序
  2. 前端布局神器display:flex
  3. python中倒着输出输入值_十五、深入Python输入和输出
  4. WEB安全基础-WEB介绍
  5. 注解java_Java注解教程及自定义注解
  6. 贺:MSN-.NET 技术交流群荣登群首页
  7. SQL索引碎片整理脚本
  8. Server Transport model
  9. php redis ip查找,PHP实现redis限制单ip、单用户的访问次数功能示例
  10. 【ACL2021】具有可解释的、鲁棒的、并具有泛化能力的三篇问答系统相关论文
  11. HyperLedger Composer 查看所有容器 | 进入指定容器
  12. SAP WM Stock Removal Strategy - StringentFIFO 在仓库号级别下的先进先出
  13. 凸优化有关的数值线性代数知识 2求解已经因式分解的矩阵的线性方程组
  14. linux版qq怎么传文件,QQ for linux终于能在线传送文件了~
  15. ffmpeg 官方文档 上篇 (译)
  16. NEFU 155 超弦(插头DP)
  17. HTML5排序罗马数字,HTML5 罗马数字时钟
  18. linux访问工具图标,linux上的编码转换工具iconv,enca,convmv
  19. 怎么在短时间内快速提高网站排名
  20. Excel 操作 插件 方方格子 工作簿未按字母顺序排列 重名工作簿名 并拆分成工作表

热门文章

  1. C#利用NPOI导出Excel
  2. iOS 设计模式浅析 0 - 前言
  3. CentOS7下 libvirt+virt-manager 虚拟机迁移配置及错误处理
  4. 日志分析(shell脚本)
  5. 山石网科-Hillstone-SC-***(SSL-***)之配置终结篇
  6. Golang读取目录文件
  7. 转:硬盘结构简介的好文(转)---MBR、分区表、CHS等概念
  8. 单选按钮、复选按钮的简单应用
  9. WebWork配置文件详解
  10. Dom对象与jQuery对象的转换