git rebase branch with all subbranches

Posted by knittl on Stack Overflow See other posts from Stack Overflow or by knittl
Published on 2010-04-28T15:27:16Z Indexed on 2010/04/28 17:57 UTC
Read the original article Hit count: 305

Filed under:
|
|

is it possible to rebase a branch with all it's subbranches in git?

i often use branches as quick/mutable tags to mark certain commits.

* master
*
* featureA-finished
*
* origin/master

now i want to rebase -i master onto origin/master, to change/reword the commit featureA-finished^

after git rebase -i --onto origin/master origin/master master, i basically want the history to be:

* master
*
* featureA-finished
* (changed/reworded)
* origin/master

but what i get is:

* master
*
* (same changeset as featureA-finished)
* (changed/reworded)
| * featureA-finished
|.* (original commit i wanted to edit)
* origin/master

is there a way around it, or am i stuck with recreating the branches on the new rebased commits?

© Stack Overflow or respective owner

Related posts about git

Related posts about rebase