The problem was my understanding of git branch --contains
. It doesn't list branches contained in the currently checked out branch, but branches which contain it.
So to know if master
contains develop
I should do
git checkout develop
git branch --contains
* develop
So there was no problem after all. As this shows, master
is not part of the list of branches which contain develop
.
While this showed that develop
did contain master
, but that's ok.
git checkout master
git branch --contains
develop
* master