2018-11-20 19:24:24 +00:00
|
|
|
#!/bin/bash
|
|
|
|
|
|
|
|
# https://git-scm.com/docs/pretty-formats
|
|
|
|
|
|
|
|
latestTag=`git describe | grep -oE "^[^-]+"`
|
|
|
|
|
2019-03-14 10:44:47 +00:00
|
|
|
rm commits.md
|
|
|
|
|
|
|
|
write() {
|
|
|
|
echo "$@"
|
|
|
|
echo "$@" >> commits.md
|
|
|
|
}
|
|
|
|
|
|
|
|
write "Comaparing $latestTag...dev"
|
2018-11-20 19:37:16 +00:00
|
|
|
|
2018-11-20 19:24:24 +00:00
|
|
|
diff=`git --no-pager log $latestTag...dev --pretty="%s (%an) (%h)"`
|
|
|
|
|
2019-03-14 10:44:47 +00:00
|
|
|
write
|
|
|
|
write "## Features"
|
|
|
|
write
|
|
|
|
res=`echo "$diff" | awk '/feat/' | grep ":" | grep -v "renovate" | sed -e 's/^/- /' | sort`
|
|
|
|
write "$res"
|
|
|
|
|
|
|
|
write
|
|
|
|
write "## Fixes"
|
|
|
|
write
|
|
|
|
res=`echo "$diff" | awk '!/feat/' | grep ":" | grep -v "renovate" | sed -e 's/^/- /' | sort`
|
|
|
|
write "$res"
|