| Parent(s) | | ce8c7caca24c1d771bdd31d4be822c9a | Commit message |
|
My question is very basic and it might looks like silly. But yes i want to know how how gerrit decides the parent (s) commit for any new change uploaded on gerrit ? Also Why I need to rebase ONLY some of my changes before i merge them?
Each Git commit has zero or more parent commits; it's a fundamental property of the repository structure. For any commit that isn't an initial commit there will always be one parent. So gerrit is showing you that value.
If you do a git log --format=raw I think it shows the parents in the commit object.
I am not sure of your second question: but if you have "fast forward only" in your repository then you will need to rebase when another commit has occurred on the repository branch in the time between when you have made your commit. So if you have a->b and a->c, only one of b and c can be pushed; the other will need rebasing (a->b->c')
Alex