Git排除了某些提交和代码更改,并将其他提交置于最前面

时间:2018-11-01 21:58:42

标签: git

我有一个开发分支,它充当所有功能分支的父级(基础)。提交日志如下所示:

ticket9: did something
ticket8: fixed something

ticket7: some action (squashed and rebased commits)
ticket7: some action (squashed and rebased commits)
ticket7: some action (squashed and rebased commits)

ticket6: implemented something

有没有办法从开发分支中取出票证7的提交和结果代码,并像下面那样链接票证6和票证8?

ticket9: did something
ticket8: fixed something
ticket6: implemented something

1 个答案:

答案 0 :(得分:1)

如果可以,请考虑执行以下操作:

这将涉及您强行推动(git push --force)重写的分支,这意味着您需要警告在同一分支上工作的同事。