Goal: check the merge with upstream needs merge commit
or rebase commit
, instead of squash commit
when managing a fork repo.
Only merge/base commit allows the original commit is preserved. otherwise the next sync will cause git merge conflict.
How to enable this: Github doc.
This is the upstream merge experiment, parent repo. See github.com/incfly/merge-exp-child
- child:main, good merge,
merge commit
, preserving the commit., incfly/merge-exp-child#1 - child:bad-tip, bad merge,
squash merge
, single commit, incfly/merge-exp-child#2 - add new commit here.
- do git pull && merge in child again in above two branches, the bad-tip sees conflicts.
- child:main, is able to consume new update, incfly/merge-exp-child#4
- child:bad-tip is not: incfly/merge-exp-child#3