I\'m on branch-X and have added a couple more commits on top of it. I want to see all the differences between MASTER and the branch that I am on in terms of commits. I could
if you want to use gitk:
gitk master..branch-X
it has a nice old school GUi
You can easily do that with
git log master..branch-X
That will show you commits that branch-X has but master doesn't.
I used some of the answers and found one that fit my case ( make sure all tasks are in the release branch).
Other methods works as well but I found that they might add lines that I do not need, like merge commits that add no value.
git fetch
git log origin/master..origin/release-1.1 --oneline --no-merges
or you can compare your current with master
git fetch
git log origin/master..HEAD --oneline --no-merges
git fetch
is there to make sure you are using updated info.
In this way each commit will be on a line and you can copy/paste that into an text editor and start comparing the tasks with the commits that will be merged.
If you want to compare based on the commit messages, you can do the following:
git fetch
git log --oneline origin/master | cut -d' ' -f2- > master_log
git log --oneline origin/branch-X | cut -d' ' -f2- > branchx_log
diff <(sort master_log) <(sort branchx_log)
I'd suggest the following to see the difference "in commits". For symmetric difference, repeat the command with inverted args:
git cherry -v master [your branch, or HEAD as default]
Not the perfect answer but works better for people using Github:
Go to your repo: Insights -> Network