From 57e670068e079e6a8fa28734a9400c4a5ace4137 Mon Sep 17 00:00:00 2001 From: Valentin Brandl Date: Mon, 5 Jun 2017 15:35:26 +0200 Subject: [PATCH] Update hook --- hooks/post-receive | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/hooks/post-receive b/hooks/post-receive index 1ecbf17..dceb8ea 100644 --- a/hooks/post-receive +++ b/hooks/post-receive @@ -12,8 +12,8 @@ rm -rf $WORKING_DIRECTORY rsync -aqz ${PUBLIC_WWW}/ $BACKUP_WWW trap "echo 'A problem occurred. Reverting to backup.'; rsync -aqz --del $BACKUP_WWW/ $PUBLIC_WWW; rm -rf $WORKING_DIRECTORY" EXIT -git clone $GIT_REPO $WORKING_DIRECTORY -cd $WORKING_DIRECTORY && git submodule update --init --recursive --remote +git clone --recursive $GIT_REPO $WORKING_DIRECTORY +# cd $WORKING_DIRECTORY && git submodule update --init --recursive --remote rm -rf $PUBLIC_WWW/* hugo -s $WORKING_DIRECTORY -d ${PUBLIC_WWW} -b "https://${MY_DOMAIN}" find $PUBLIC_WWW -type f \( -name '*.html' -o -name '*.js' -o -name '*.css' -o -name '*.xml' -o -name '*.svg' \) -exec gzip -v -k -f --best {} \; -exec touch -r {} "{}.gz" \;