From 4615d943144be9aa303c5ce3e8e8b52cb82840fa Mon Sep 17 00:00:00 2001 From: Carl Worth Date: Sun, 3 May 2020 11:01:26 -0700 Subject: [PATCH] Add a simple "make deploy" target To simplify the deployment which I'd previously been doing manually. This will deploy only the state of committed code. --- Makefile | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 Makefile diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..f490fec --- /dev/null +++ b/Makefile @@ -0,0 +1,11 @@ +PUBLISH_HOST=cworth.org +PUBLISH_DIR=/srv/families.cworth.org/www + +DO_NOT_PUBLISH="Makefile" + +deploy: + rm -rf .deploy-source + git clone . .deploy-source + rm -rf .deploy-source/.git + (cd .deploy-source; rm $(DO_NOT_PUBLISH); rsync -avz ./ --delete --delete-after $(PUBLISH_HOST):$(PUBLISH_DIR) ) + rm -rf .deploy-source -- 2.43.0