feature-branch----C---D
/
develop---A---B
/
master
I have a branch feature-branch that has been merged off a branch develop. This develop branch is an ongoing branch that is merged into master weekly. I’ve completed work on this feature-branch that is decided after the fact that it needs to go directly into master. I don’t want commits A and B that are in develop to go into master though. Is there a nice solution that will allow me to get commits C and D into master without cherry-picking them?
Thanks,
Braden
You should rebase
feature-branchonto master, removing its dependencies on commits A and B. If C and D have real, code-level semantic dependencies on A and B, then of course you are out of luck.The following sequence of commands will modify
feature-branchto be based off ofmasterinstead ofdevelop: