From 3e8089ec3c6d887a36d6605e534324f492d8815b Mon Sep 17 00:00:00 2001 From: Vidhu Kant Sharma Date: Thu, 23 Nov 2023 21:44:30 +0530 Subject: added hugo-upload script --- .scripts/hugo-upload | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100755 .scripts/hugo-upload diff --git a/.scripts/hugo-upload b/.scripts/hugo-upload new file mode 100755 index 0000000..3c45a0f --- /dev/null +++ b/.scripts/hugo-upload @@ -0,0 +1,12 @@ +#!/usr/bin/env bash + +if [ -f .hugo_upload ]; then + source .hugo_upload + + rm -r public/ + hugo --quiet + + rsync -rtvzP public/ "$user@$host:$target_dir" +else + echo ".hugo_upload file not found in $(pwd)" +fi -- cgit v1.2.3