I would like to take a commit and copy it somewhere else in my repository.
Current situation:
A--B--C--D (branch1)
\
E--F (branch2)
Desired situation:
A--B--C--D--F'(branch1)
\
E--F (branch2)
It is important that F remains in the repository. I don't want to rewrite history because F might be public.
The state of the repository (source code) represented F and F' should be exactly the same. Yes, what was introduced C and D might be lost.
I do not want to replay E and F on top of D. I have looked into cherry-pick
and rebase
, but it seems that they delete the original commits or simply replay the changes on top of the target.