]> git.cworth.org Git - lmno.games/commitdiff
Add a simple Makefile with a "make deploy" target
authorCarl Worth <cworth@cworth.org>
Sat, 16 May 2020 20:05:43 +0000 (13:05 -0700)
committerCarl Worth <cworth@cworth.org>
Sat, 16 May 2020 20:05:43 +0000 (13:05 -0700)
This doesn't do any deleting of pre-existing files, (to avoid deleting
any web content from sub directories that aren't being maintained in
this repository). We'll need to eventually sort out a better solution
for that.

Makefile [new file with mode: 0644]

diff --git a/Makefile b/Makefile
new file mode 100644 (file)
index 0000000..fb39f7f
--- /dev/null
+++ b/Makefile
@@ -0,0 +1,12 @@
+DEPLOY_HOST=lmno.games
+DEPLOY_DIR=/srv/lmno.games/www
+DO_NOT_DEPLOY="Makefile"
+
+deploy:
+       rm -rf .deploy-source
+       git clone . .deploy-source
+       rm -rf .deploy-source/.git
+       (cd .deploy-source; rsync -avz \
+               --exclude=$(DO_NOT_DEPLOY) \
+               ./ $(DEPLOY_HOST):$(DEPLOY_DIR) )
+       rm -rf .deploy-source