Git refusing to merge unrelated histories on rebase

后端 未结 23 2667
旧巷少年郎
旧巷少年郎 2020-11-22 08:30

During git rebase origin/development the following error message is shown from Git:

fatal: refusing to merge unrelated histories
Error redoing m         


        
23条回答
  •  执笔经年
    2020-11-22 08:49

    I struggled with this as well, but I managed to find a workaround.

    When you run into the error above, just cherry-pick the merge commit and then continue the rebase:

    git cherry-pick -m 1 1234deadbeef1234deadbeef
    git rebase --continue
    

提交回复
热议问题