我有以下情况:
合并前的主要分支:
│ └── dir1
│ │ └── python1
│ │ │ └── test1.py
│ └── dir2
│ │ └── python2
│ │ │ └── test2.py
│ └── dir3
│ │ └── python3
│ │ │ └── test3.py
合并后的主分支:
│ └── dir1
│ └── dir2
│ │ └── python1
│ │ │ └── test1.py
│ │ └── python2
│ │ │ └── test2.py
│ │ └── python3
│ │ │ └── test3.py
│ └── dir3
合并前的功能分支(test4.py
历史记录中有 10 次提交):
│ └── dir1
│ │ └── python1
│ │ │ └── test4.py
从功能分支合并后的主分支(使用git merge -s ort
和解决不存在的冲突test4.py
):
│ └── dir1
│ └── dir2
│ │ └── python1
│ │ │ └── test1.py
│ │ │ └── test4.py
│ │ └── python2
│ │ │ └── test2.py
│ │ └── python3
│ │ │ └── test3.py
│ └── dir3
问题是所有的历史都test4.py
被删除了......知道它为什么会发生以及它是否可以避免?