The code has B分支
and A分支
Now we need to merge B分支
onto A分支
B分支
There is development 1 code for and development 2 code.
The submitted code history of development 1 and development 2: 1->2->1->1
The question is how to remove the code of development 2 and only merge the code of development 1 into the A branch?
Please give me some advice~~
It seems that you can only create a new branch from branch A? After development is completed, go directly to branch A instead of going through branch B and then to branch A
git rebase B A
Revert 2 commits on branch B, and then do a rebase and merge