DEV Community

Discussion on: Explain Git Rebase just like I'm five

Collapse
 
pratikaambani profile image
Pratik Ambani

Awesomely explained, I've a doubt, who will decide on which floor this bicycle store would be located??

Will it be on the same floor in new building where the bicycle store was built in other building??

Collapse
 
nuc profile image
Georgios Giannoutsos Barkas

Rebase will find the common ancestor (the lego base plate) and split your branch (the building without the bicycle store) from there.

It will point the head to the tip of the other branch (top level of the building with the bicycle store) and will replay all your commits on top of that.

Thus, the bicycle store, along with all other levels of that building, will stay where they were first built.

I hope that's clear :)