当我从我的队友那里引入更改时,我通常会使用rebase,并且经常会有冲突:
...
CONFLICT (content): Merge conflict in app/views/search/index.html.erb
Auto-merging public/stylesheets/application.css
CONFLICT (content): Merge conflict in public/stylesheets/application.css
Failed to merge in the changes.
Patch failed at 0001 organizing
When you have resolved this problem run "git rebase --continue".
If you would prefer to skip this patch, instead run "git rebase --skip".
To restore the original branch and stop rebasing run "git rebase --abort".因此,在打开每个有冲突的文件后,修复它,然后提交修复的文件:
~/Projects/myApp[956f6e1...]% git rebase --continue
You must edit all merge conflicts and then
mark them as resolved using git add我仍然得到相同的错误...
~/Projects/myApp[64b3779...]% git rebase --continue
Applying: organizing
No changes - did you forget to use 'git add'?
When you have resolved this problem run "git rebase --continue".
If you would prefer to skip this patch, instead run "git rebase --skip".
To restore the original branch and stop rebasing run "git rebase --abort".我一直有这个问题,但我猜我从来没有真正选择解决它,我总是我只是变得懒惰和git rebase --skip。
我如何真正以正确的方式解决冲突?
发布于 2021-02-24 21:32:52
我已经解决了合并冲突,但我仍然看到
您有未合并的路径。
我所要做的就是git add <file that had conflicts>,从那时起一切都很顺利。
https://stackoverflow.com/questions/3611260
复制相似问题