I find it useful to be able to quickly generate a list of all changes in the current branch which have not yet been merged into master. It’s a good way to come up with a change list when doing a release for instance. To do this in git you can use the following:
git log master.. --pretty="%s"
This assumes that you are on a branch which is off master (if you are on master you could use the path ..my-branch) and that the changes have not yet been merged into master, and it will give you a list showing only the commit messages, ready for copying and pasting into that release note.
Advertisement