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

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

问题描述

我分叉了一个github repo,并在我的github repo上工作。

我已经完成了pull请求并完成了。

之后,上游有更多的提交,所以现在我想rebase,我想这就是我必须做的。

但是我得到这些合并冲突:

 首先,倒带头重放你的工作... 
应用:第135期主页刷新
使用索引信息重建基础树...
:17:尾随空格。
%h4
警告:1行添加空格错误。
回退到补丁库和3路合并...
自动合并应用程序/ views / layouts / application.html.haml
CONFLICT(内容):合并app / views中的冲突/layouts/application.html.haml
自动合并app / views / home / index.html.haml
CONFLICT(内容):合并app / views / home / index.html.haml中的冲突
自动合并app / views / home / _group_projects.html.haml
CONFLICT(内容):在app / views / home / _group_projects.html.haml中合并冲突
在更改中合并失败。
补丁失败,在0001发行135主页刷新

当你解决这个问题时,运行git rebase --continue。
如果您希望跳过此修补程序,请运行git rebase --skip。
检出原始分支并停止重新分配运行git rebase --abort。

我不知道如何解决这些问题,请帮助。

解决方案

重新激活可能是一件非常头疼的事情。您必须解决合并冲突并继续重新分配。例如,您可以使用合并工具(根据您的设置而不同)

  git mergetool 

然后添加并提交您的更改并继续

  git rebase --continue 

祝您好运

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 and commit your changes and go on

git rebase --continue

Good luck

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

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