Created
January 26, 2016 15:01
-
-
Save replsv/507d76f7e02ee01308e6 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
while [[ $# > 1 ]] | |
do | |
key="$1" | |
case $key in | |
-i|--initial) | |
INITIAL_COMMIT="$2" | |
shift # past argument | |
;; | |
-f|--final) | |
FINAL_COMMIT="$2" | |
shift # past argument | |
;; | |
--default) | |
DEFAULT=YES | |
;; | |
*) | |
;; | |
esac | |
shift # past argument or value | |
done | |
echo $INITIAL_COMMIT | |
echo "### Release: ${FINAL_COMMIT}" | |
echo "Changes:" | |
echo "\`\`\`" | |
git log ${INITIAL_COMMIT}..${FINAL_COMMIT} --graph --decorate --format=format:"%C(bold blue)%h%C(reset) - %C(white)%s%C(reset)" | |
echo "\`\`\`" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment