summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorPatrick McDermott <patrick.mcdermott@libiquity.com>2019-08-01 20:19:03 (EDT)
committer Patrick McDermott <patrick.mcdermott@libiquity.com>2019-08-01 20:19:03 (EDT)
commit5c06c0c7bb7ac6c82368d510f1462ece2e61c62f (patch)
treea33501a26cadac207f9acc5ef15ddd64c99a354b
parentd242cc814cf33d24b854271df1c76386723d9859 (diff)
build: Set GIT_DIR earlier in announce script
-rwxr-xr-xscripts/announce-release.sh4
1 files changed, 2 insertions, 2 deletions
diff --git a/scripts/announce-release.sh b/scripts/announce-release.sh
index ae26070..dee51c1 100755
--- a/scripts/announce-release.sh
+++ b/scripts/announce-release.sh
@@ -17,6 +17,8 @@ version="${2}"
package_name="${3}"
srcdir="${0%/scripts/announce-release.sh}"
+export GIT_DIR="${srcdir}/.git"
+
heading()
{
local name="${1}"
@@ -51,8 +53,6 @@ old_tag="$(git tag --sort=-creatordate | sed -n '2{p;q;}')"
# Empty tree SHA-1 hash:
[ -z "${old_tag}" ] && old_tag='4b825dc642cb6eb9a060e54bf8d69288fbee4904'
-export GIT_DIR="${srcdir}/.git"
-
shortlog="$(git shortlog "${old_tag}..HEAD" | \
sed '/^..*$/s/^//')"
if [ $(printf '%s\n' "${shortlog}" | wc -l) -gt 100 ]; then