Git refusing to merge unrelated histories on rebase

后端 未结 23 2364
旧巷少年郎
旧巷少年郎 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条回答
  •  旧时难觅i
    2020-11-22 08:56

    I tried git pull --allow-unrelated-histories didn't work, but what solves this issue for me was:

    1. I copied all the files on my desktop repository to another folder and then deleted the folder.

    2. Then I clone the repo again because it is a new project.

    3. When I copied my files again and push it worked like charm.

提交回复
热议问题