diff --git a/Makefile b/Makefile index 9ecbb22..2bf1634 100644 --- a/Makefile +++ b/Makefile @@ -13,6 +13,11 @@ build-prod: serve: hugo server -D -F +deploy: + @if [ -n "$$KEY" ]; then eval "$$(ssh-agent)"; echo "$$KEY" | ssh-add -; fi + if [ -z "$$USERNAME" ] || [ -z "$$SSH_HOST" ] || [ -z "$$TARGET" ]; then exit 1; fi + rsync --progress -avz --delete public/ "$$USERNAME@$$SSH_HOST:$$TARGET" + .PHONY: clean clean: $(RM) -r public