你如何解决错误“中止未提交的更改"?尝试“hg 合并"时,什么时候没有变化? [英] How do you resolve the error "abort uncommitted changes" when trying to "hg merge", when there are no changes?

查看:61
本文介绍了你如何解决错误“中止未提交的更改"?尝试“hg 合并"时,什么时候没有变化?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我重新检查了我的 mercurial 项目并更新了提示.我正在尝试与另一个分支合并,但收到错误 abort uncommitted changes.

I did a fresh checkout of my mercurial project and updated to the tip. I am trying to merge with another branch, but get the error abort uncommitted changes.

> hg up
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
updated to "f9e1acf1f459: <commit message>"
1 other heads for branch "<branch>"

> hg merge
abort: uncommitted changes
(use 'hg status' to list changes)

> hg status



> hg status -i



> hg status -u



> hg summary
parent: 7008:f9e1acf1f459 tip
 <message for last commit>
branch: <branch>
commit: (clean)
update: 26 new changesets, 2 branch heads (merge)

>hg version
Mercurial Distributed SCM (version 4.9.1)
(see https://mercurial-scm.org for more information)

Copyright (C) 2005-2019 Matt Mackall and others
This is free software; see the source for copying conditions. There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

我尝试使用旧版本的 mercurial (4.7.1),结果相同.

I have tried using an older version of mercurial (4.7.1), with the same results.

我该如何解决这个问题?

How do I resolve this?

推荐答案

我遇到了同样的问题 -(5.7 版).在搜索并尝试了很多事情之后,我找到了一种解决方法:

I had the same problem - (version 5.7). After searching and trying a lot of things I've found one workaround:

delete everything except .hg directory
hg update --clean branch-name

我仍然不知道为什么 hg status 显示没有变化并且 hg merge 因为有变化而中止

I still don't know why hg status shows no changes and hg merge aborts because there are changes

这篇关于你如何解决错误“中止未提交的更改"?尝试“hg 合并"时,什么时候没有变化?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆