Multiple default branches

Discussion area about developing or extending OGRE, adding plugins for it or building applications on it. No newbie questions please, use the Help forum for that.
Post Reply
al2950
OGRE Expert User
OGRE Expert User
Posts: 1210
Joined: Thu Dec 11, 2008 7:56 pm
Location: Bristol, UK
x 80

Multiple default branches

Post by al2950 » Wed Feb 13, 2019 11:39 am

I have noticed recently that multiple (3) default branches have appeared. Just wanted to check it was not an accident . It looks like it might be a git thing!
0 x

User avatar
Zonder
Ogre Magi
Posts: 1133
Joined: Mon Aug 04, 2008 7:51 pm
Location: Manchester - England
x 22

Re: Multiple default branches

Post by Zonder » Sat Feb 16, 2019 1:06 pm

you can't have more than 1 default :D

sure your local not messed up in some way?
0 x
There are 10 types of people in the world: Those who understand binary, and those who don't...

al2950
OGRE Expert User
OGRE Expert User
Posts: 1210
Joined: Thu Dec 11, 2008 7:56 pm
Location: Bristol, UK
x 80

Re: Multiple default branches

Post by al2950 » Wed Feb 20, 2019 8:38 pm

Although by default you can only have 1 branch head you can force it too have multiple. However you are correct as my repo is really messed up! Not sure how it happened as this repo has only been used for ogre 2.x patches :?
0 x

User avatar
dark_sylinc
OGRE Team Member
OGRE Team Member
Posts: 4138
Joined: Sat Jul 21, 2007 4:55 pm
Location: Buenos Aires, Argentina
x 267
Contact:

Re: Multiple default branches

Post by dark_sylinc » Wed Feb 20, 2019 11:56 pm

Zonder wrote:
Sat Feb 16, 2019 1:06 pm
you can't have more than 1 default :D

sure your local not messed up in some way?
That's for git. In Mercurial you can have multiple heads for the same branch, and they're all "valid".

When it comes to the default branch, Pavel works on git and then ports his changes to Mercurial. Sometimes it gets screwed up and an alternate history gets created (i.e. two heads with nearly-identical commit ancestry until the common commit where the split happened appears). When we find out about this, we strip the bad dupe.

But if you pulled from the repo while the dupes weren't fixed, you have to strip the dupes from your local repo as well (using the strip extension, Modify History -> Strip) otherwise it gets messed up, or just clone the repo again from scratch.
If you don't do this and later it happens again, and you pull, you may end up with more than one dupe (i.e. 3 heads, then 4 heads, 5 heads...)
0 x

al2950
OGRE Expert User
OGRE Expert User
Posts: 1210
Joined: Thu Dec 11, 2008 7:56 pm
Location: Bristol, UK
x 80

Re: Multiple default branches

Post by al2950 » Thu Feb 21, 2019 12:53 pm

Ah ha, I knew it... Stupid git :wink: !

Thanks for the info
0 x

Post Reply