How do I fix a merge conflict due to removal of a file in a branch?

后端 未结 3 1315
不知归路
不知归路 2020-11-30 17:46

I have create a dialog branch and when I try to merge it to master branch. There are 2 conflicts. I don\'t know how to resolve CONFLICT (del

3条回答
  •  生来不讨喜
    2020-11-30 18:15

    If you are using Git Gui on windows,

    1. Abort the merge
    2. Make sure you are on your target branch
    3. Delete the conflicting file from explorer
    4. Rescan for changes in Git Gui (F5)
    5. Notice that conflicting file is deleted
    6. Select Stage Changed Files To Commit (Ctrl-I) from Commit menu
    7. Enter a commit comment like "deleted conflicting file"
    8. Commit (ctrl-enter)
    9. Now if you restart the merge it will (hopefully) work.

提交回复
热议问题