从一个分支A切换到另一个分支B后,对切换后的B分支进行pull操作,因为pull操作实际上包含了fetch+merge操作,在执行 merge操作时,由于很长时间没有对B分支执行过pull/merge操作,本地的B分支库与remote中的B分支库中的差异很大(且这些差异是其他 同事开发的文件),merge时产生冲突,使得B分支的状态为merging,其实是指merge失败,还停留在merge状态,也不能执行pull操 作。这时没有解决冲突,而是从B分支上执行checkout/switchto操作,试图再切换其他分支时,报错,显示有冲突。

原因为:merge失败,有conflicts没解决,可以:

1、解决conflicts后再次执行merge;

2、回退到merge前

恩,既然merge冲突是其他同事的文件,我不需要去resolve conflicts,那就退回merge前吧,单纯的改我的文件再push吧,执行以下代码:

    git reset --merge  

https://stackoverflow.com/questions/6006737/git-merge-errors

you need to resolve your current index first 已解决的更多相关文章

  1. git you need to resolve your current index first 解决办法

    当使用git checkout 切换分支时会提示you need to resolve your current index first,使用如下命令即可解决. $ git reset --merge

  2. git分支merge冲突 error: you need to resolve your current index first

    问题: 执行切换代码分支 git checkout featrue_2019-06-24 ,报错如下: error: you need to resolve your current index fi ...

  3. [已解决]This dependency was not found: * common/stylus/index.styl in ./src/main.js To install it, you can run: npm install --save common/stylus/index.styl

    出现 This dependency was not found: * common/stylus/index.styl in ./src/main.js To install it, you can ...

  4. 多线程中使用HttpContext.Current为null的解决办法

    HttpContext.Current.Server.MapPath(logFile)   这个是得到具体路径的方法  正常情况下是可以的 多线程情况下就为null 下边的代码原本的作用是把网站的异常 ...

  5. System.Web.HttpContext.Current.Session为NULL解决方法

    http://www.cnblogs.com/tianguook/archive/2010/09/27/1836988.html 自定义 HTTP 处理程序,从IHttpHandler继承,在写Sys ...

  6. phpcms无法读取index.html的解决步骤

    代码如下: phpcms\modules\content\classes\html.class.php 查找 复制代码 代码如下: /** * 更新首页 */ public function inde ...

  7. Unable to resolve target 'android-8'类似错误的解决办法

    导入android项目出现:出现Unable to resolve target 'android-8'错误及其他的一些解决办法 - 为梦想而飞 - 博客频道 - CSDN.NEThttp://blo ...

  8. [已解决]ValueError: row index was 65536, not allowed by .xls format

    报错: ValueError: row index was 65536, not allowed by .xls format 解决方案: xlrd和xlwt处理的是xls文件,单个sheet最大行数 ...

  9. java开发过程中,报错Dangling meta character '*' near index 0,解决办法

    1.split方法转化字符串为数组: String[] strPicArr = map.get("hw_pic").toString().split("*"); ...

随机推荐

  1. Hive中使用LZO

    hive 中使用lzo 1 启动hive 错误Exception in thread "main" java.lang.NoClassDefFoundError: org/apac ...

  2. Python基础—14-邮件与短信

    邮件与短信 邮件发送 简介: 邮件服务器.账户.密码 相关协议:SMTP.POP3.IMAP 默认TCP协议端口:25 用途:经常用在一个网站的注册激活.通知.找回密码等场景 库:smtplib 示例 ...

  3. React中需要多个倒计时的问题

    最近有一个需求是做一个闪购列表,列表中每一个商品都有倒计时,如果每一个倒计时都去生成一个setTimeout的话,一个页面就会有很多定时器,感觉这种做法不是非常好,于是换了一个思路. 思路是这样的,一 ...

  4. POJ 2398--Toy Storage(叉积判断,二分找点,点排序)

    Toy Storage Time Limit: 1000MS   Memory Limit: 65536K Total Submissions: 6534   Accepted: 3905 Descr ...

  5. SAP物料主数据的屏幕字段控制,必输,隐藏

    http://www.cnblogs.com/275147378abc/p/5699077.html 1.事务码MM01,把物料组设为选填字段. 2.找到物料组的屏幕字段. 3.在后台根据屏幕字段找到 ...

  6. ABAP术语-Business Scenario

    Business Scenario 原文:http://www.cnblogs.com/qiangsheng/archive/2008/01/12/1035980.html End-to-end co ...

  7. android Service服务简介(一)

    作为android的四大组件之一,服务也少不了很多重要的知识点.下面我们从最基本的开始学习. 1.1服务的创建 首先创建一个ServiceTest类继承Service.我们会重写onCreate(), ...

  8. 【PHP】PHP常用数组(Array)函数整理

    整理了一份PHP开发中数组操作大全,包含有数组操作的基本函数.数组的分段和填充.数组与栈.数组与列队.回调函数.排序.计算.其他的数组函数等. 一.数组操作的基本函数 数组的键名和值 array_va ...

  9. php-7.2.3源代码和php-5.6.26源代码摘录,对比 “汇编php文件”和“执行opcode代码”

    php-7.2.3 在“汇编php文件”和“执行opcode代码”上做了大量改变php-5.6.26 没见到支持抽象语法树的相关代码,php-7.2.3 见到支持抽象语法树的相关代码php-5.6.2 ...

  10. 怎么修复网站漏洞之metinfo远程SQL注入漏洞修补

    2018年11月23日SINE网站安全检测平台,检测到MetInfo最新版本爆出高危漏洞,危害性较大,影响目前MetInfo 5.3版本到最新的 MetInfo 6.1.3版本,该网站漏洞产生的主要原 ...