Suppose I have something like this, with branches foo
and bar
.
* e4417814 (HEAD -> master) A
* 91a3e3d2 B
| * afde3756 (foo) C
| * 6013afc7 D
| * eb9e3403 (bar) E
| * e098075d F
| * 577c0471 G
|/
* f15d83fc H
* 5e06f896 I
If I do this:
git checkout foo
git rebase master
It will rebase foo
onto master
but leave bar
behind. Something like this:
* 92eba834 (HEAD -> foo) C
* 938eb379 D
* be8377ab E
* 2bbe45b4 F
* 90aa0125 G
* e4417814 (master) A
* 91a3e3d2 B
| * eb9e3403 (bar) E
| * e098075d F
| * 577c0471 G
|/
* f15d83fc H
* 5e06f896 I
I have to do something annoying like this to fix it.
git branch -f bar be8377ab
Is there any way to tell git to update any other branch labels too when it rebases?