From 457e894d357b15aa7a0eb1e72bb4921cdc591e9c Mon Sep 17 00:00:00 2001 From: Christoph Cullmann Date: Sun, 4 Aug 2019 12:03:31 +0200 Subject: [PATCH] export git env stuff always --- server.sh | 4 ++++ update.sh | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/server.sh b/server.sh index a4a84ee..41da2bf 100755 --- a/server.sh +++ b/server.sh @@ -3,5 +3,9 @@ # failures are evil set -e +# export the GIT env vars we need to have links in the footer +export GIT_COMMIT_SHA=`git rev-parse --verify HEAD` +export GIT_COMMIT_SHA_SHORT=`git rev-parse --short HEAD` + # run hugo in local server mode, show all stuff exec ./hugo server -D --buildFuture diff --git a/update.sh b/update.sh index 849a168..e61bd41 100755 --- a/update.sh +++ b/update.sh @@ -6,10 +6,11 @@ set -e # update our clone git pull -q &> /dev/null -# rerun hugo generator # export the GIT env vars we need to have links in the footer export GIT_COMMIT_SHA=`git rev-parse --verify HEAD` export GIT_COMMIT_SHA_SHORT=`git rev-parse --short HEAD` + +# rerun hugo generator ./hugo --minify # copy .htaccess