我正在尝试应用一个补丁程序,这是我从http://www.winehq.org/pipermail/wine-devel/2014-May/104356.html获得的。我将其复制到文本编辑器中,并将其保存为my.patch
(我需要修复电子邮件,它已经被混淆了)。
我试图将它应用于Git,但我得到了以下错误:
sashoalm@sashoalm-VirtualBox:~/Desktop/wine-git$ git am --signoff <my.patch
previous rebase directory /home/sashoalm/Desktop/wine-git/.git/rebase-apply still exists but mbox given.
这个神秘的错误信息让我不知道哪里出了问题,也不知道我需要做些什么才能让它正常工作。这个错误意味着什么?我该怎么解决呢?
发布于 2015-08-05 09:15:49
git am --abort
为我工作,但git rebase --abort
没有。
发生了什么:我试图应用一个修补程序,但它已经损坏(很可能是被Gmail copy pasting in body破坏的):
git am bad.patch
吉特说:
Applying: python: fix Linetable case to LineTable in docstrings and comments
fatal: corrupt patch at line 56
Patch failed at 0001 python: fix Linetable case to LineTable in docstrings and comments
The copy of the patch that failed is found in:
/home/ciro/git/binutils-gdb/src/.git/rebase-apply/patch
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".
注意git如何给出解决方案:To restore the original branch and stop patching, run "git am --abort".
然后我显然忽略了这个消息,并立即尝试了一个固定的版本:
git am good.patch
得到了错误。
发布于 2014-06-09 13:55:37
好的,原来我需要删除目录.git/rebase-apply
。它在那之后起作用(或者至少给我不同的错误,说电子邮件又错了)。我仍然不知道这个错误到底意味着什么,也不知道为什么会有错误。
编辑:,如下面的评论所示,git am --abort
或git rebase --abort
可能是解决问题的更好方法,但我还没有对其进行测试。
https://stackoverflow.com/questions/24121709
复制相似问题