Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/bin/bash
- # git-branch-diff
- #
- # Shows the difference in commits between two branches. If only
- # one branch is given, the other defaults to HEAD.
- #
- # msnider$
- if [[ $# -eq 1 ]] ; then
- git log --oneline HEAD..$1
- elif [[ $# -eq 2 ]] ; then
- git log --oneline $1..$2
- else
- echo "error: must specify at least one branch" >&2; exit 1
- fi
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement