Possible Duplicate:
Find the parent branch of a branch
I have made a new feature branch but I have forgotten form where did I branch this feature branch. Now the feature is complete but I don't know in which branch I have to merge Who do I find the branch that I have branched from?
You can use git branch --contains to list all the branches descended from the tip of develop , then use grep to make sure feature is among them.
In order to compare two branches easily, you have to use the “git diff” command and provide the branch names separated by dots. Using this command, Git will compare the tip of both branches (also called the HEAD) and display a “diff” recap that you can use to see modifications.
I believe you can use gitk or git-log to better visualize your commits history.
Like this:
gitk --all
or
git log --graph --decorate
You can a list of child branches by typing: git branch --contains
Only if you don't have many branches that could be the parent branch, I think it could be useful
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With