git rebase 合并冲突 [英] git rebase merge conflict

查看:40
本文介绍了git rebase 合并冲突的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个 github 存储库并在我的 github 存储库上工作.
我已经提出了拉取请求,并已完成.

I forked a github repo and worked on my github repo.
I have made pull-requests and it was completed.

在那之后上游有更多的提交,所以现在我想变基,我想这就是我必须做的.
但我遇到了这些合并冲突:

After that the upstream had some more commits so now I want to rebase, I guess thats what I have to do.
But I'm getting these merge conflicts:

First, rewinding head to replay your work on top of it...
Applying: Issue 135 homepage refresh
Using index info to reconstruct a base tree...
<stdin>:17: trailing whitespace.
      %h4 
warning: 1 line adds whitespace errors.
Falling back to patching base and 3-way merge...
Auto-merging app/views/layouts/application.html.haml
CONFLICT (content): Merge conflict in app/views/layouts/application.html.haml
Auto-merging app/views/home/index.html.haml
CONFLICT (content): Merge conflict in app/views/home/index.html.haml
Auto-merging app/views/home/_group_projects.html.haml
CONFLICT (content): Merge conflict in app/views/home/_group_projects.html.haml
Failed to merge in the changes.
Patch failed at 0001 Issue 135 homepage refresh

When you have resolved this problem run "git rebase --continue".
If you would prefer to skip this patch, instead run "git rebase --skip".
To check out the original branch and stop rebasing run "git rebase --abort".

我不知道如何解决这些问题,请帮忙.

I don't know how to fix these, please help.

推荐答案

变基确实是一个令人头疼的问题.您必须解决合并冲突并继续变基.例如,您可以使用合并工具(根据您的设置而有所不同)

Rebasing can be a real headache. You have to resolve the merge conflicts and continue rebasing. For example you can use the merge tool (which differs depending on your settings)

git mergetool

然后添加您的更改并继续

Then add your changes and go on

git rebase --continue

祝你好运

这篇关于git rebase 合并冲突的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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