我一直在浏览"git merge-base",手册页,我无法理解多个合并库是如何发展的.具体来说,我挂在手册页中的下图中:
When the history involves criss-cross merges, there can be more than one best common
ancestor for two commits. For example, with this topology:
---1---o---A
\ /
X
/ \
---2---o---o---B
both 1 and 2 are merge-bases of A and B. Neither one is better than the other (both
are best merge bases). When the --all option is not given, it is unspecified which
best one is output.
Run Code Online (Sandbox Code Playgroud)
我无法理解如何创造这种情况.我试图使用测试存储库在分支之间重新创建这种纵横交错的合并情况,但我无法复制它.在所有情况下,我总是最终得到A和B指向的1个合并提交(而不是A和B指向独立的合并提交,如图所示).
谁能说明这种情况会怎样?这是常见情况还是错误情况?