From 8ad87f8771da116ce802b252bdb64770aed1bff8 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Tue, 02 Sep 2014 11:00:24 -0400 Subject: scripts/announce-release.sh: Shortlog and diffstat --- diff --git a/scripts/announce-release.sh b/scripts/announce-release.sh index a718cc6..dcf84bb 100755 --- a/scripts/announce-release.sh +++ b/scripts/announce-release.sh @@ -23,6 +23,10 @@ news="$(sed -n ' p; }; ' "${srcdir}/NEWS")" +old_version="$(sed -n "/^${package_name} version /p;" "${srcdir}/NEWS" | \ + sed -n "2{ s/^${package_name} version //p; };")" + +export GIT_DIR="${srcdir}/.git" /usr/sbin/sendmail \ -f pj+proteanos-ml@pehjota.net proteanos-dev@lists.proteanos.com <<-EOF @@ -64,6 +68,19 @@ news="$(sed -n ' ${news} + Shortlog of Changes Since Version ${old_version} + ==================================$(printf '%s\n' "${old_version}" | \ + sed 's/./=/g') + + $(git shortlog "${package}/${old_version}..HEAD" | sed '/^..*$/s/^/ /') + + Diffstat of Changes Since Version ${old_version} + ==================================$(printf '%s\n' "${old_version}" | \ + sed 's/./=/g') + + $(git diff --stat=69 --color=never "${package}/${old_version}..HEAD" | \ + sed 's/^/ /') + -- $(: Just something to follow the trailing space) Patrick "P. J." McDermott http://www.pehjota.net/ -- cgit v0.9.1