I have a branch that looks like this:
A->B->C->D->...->Z ^ 1->2-^
where C is a merge from 2 an
C
2
You can rebase D to Z onto B. The documentation for rebase even discusses some similar situations. This should be doable in one command.
D
Z
B