Merge error after converting Git submodule to subtree

后端 未结 4 1357
时光说笑
时光说笑 2021-02-07 05:36

I have a project where I was originally using submodules for some dependent code. It turns out that submodules are not really appropriate for this project (and they are hard to

4条回答
  •  广开言路
    2021-02-07 06:05

    It tried

    git fetch --all

    git reset --hard origin/master

    but it doesn't work.

    You can use the 'ours' merge strategy:

    git merge -s ours old-master

    You can also use git-stash to save your changes then git-stash apply to restore them.

提交回复
热议问题