From 588d5736146d13c7f0c15fc306329ef8152a3510 Mon Sep 17 00:00:00 2001 From: Dylan Lloyd Date: Fri, 10 Feb 2023 19:54:17 -0500 Subject: [PATCH] Add deploy and git perm fix to Makefile --- .gitignore | 1 + Makefile | 17 +++++++++++++++-- 2 files changed, 16 insertions(+), 2 deletions(-) diff --git a/.gitignore b/.gitignore index 920a31d..57fc3f9 100644 --- a/.gitignore +++ b/.gitignore @@ -4,3 +4,4 @@ _site .jekyll-metadata vendor disinclined.org +disinclined.org.tgz diff --git a/Makefile b/Makefile index 5c58f53..04f9f5e 100644 --- a/Makefile +++ b/Makefile @@ -1,12 +1,25 @@ default: site -build site: _site +hostname = 69.164.210.222 +sitename = disinclined.org + +build site: git submodule update cp ~/src/resume/resume.{pdf,html} . - bundle exec jekyll build -d disinclined.org --trace + bundle exec jekyll build -d $(sitename) --trace serve: bundle exec jekyll serve --trace --verbose --livereload upgrade: bundle update + +deploy: + tar -czf $(sitename).tgz $(sitename) + scp $(sitename).tgz $(hostname): + ssh -t $(hostname) tar -xf $(sitename).tgz + ssh -t $(hostname) sudo rsync -a ~dylan/$(sitename) /srv/http/ + rm $(sitename).tgz + +fix-git-permissions: + ssh -t $(hostname) sudo -u git /var/lib/gitolite3/update-permissions -- 2.30.2