Answer the question
In order to leave comments, you need to log in
How to see the graph of all parents of a given branch?
e.g. temp1 => feature1 => main
Answer the question
In order to leave comments, you need to log in
I think that we need to read again what branches and commits are in git.
There is no relationship between branches in git. A branch is just a pointer to a commit. Each commit has a parent(s) and that's it.
Those. not “from the main branch create feature1”, but “create a new pointer to the commit that the main branch now points to (or more often just the current commit) and call it feature1”. Everything. feature1 doesn't know anything about any main branch, so the question about the branch's parent is meaningless.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question