diff options
author | Romain Gonçalves <me@rgoncalves.se> | 2024-05-18 21:44:36 +0200 |
---|---|---|
committer | Romain Gonçalves <me@rgoncalves.se> | 2024-05-18 21:44:36 +0200 |
commit | 69d7464feafa554ec86a0e8020ef5ce49dc85b7b (patch) | |
tree | 24901aa12cfbdad81eb210dbc9f3ab9df8a1f558 | |
download | sousleciel.lol-69d7464feafa554ec86a0e8020ef5ce49dc85b7b.tar.gz |
feat: init Makefile
-rw-r--r-- | Makefile | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..3a34467 --- /dev/null +++ b/Makefile @@ -0,0 +1,29 @@ +.POSIX: + +REMOTE_HOST := root@rgoncalves.se +REMOTE_DIR := /var/www/htdocs/sousleciel.lol +OUTPUT_DIR := ./out +TEMPORARY_DIR := ./tmp +PATH := $(PATH):../ssg + +SSG_WEBSITE_DOMAIN := sousleciel.lol +SSG_WEBSITE_TITLE := Sous le ciel +SSG_WEBSITE_DESCRIPTION := sous le ciel + +.PHONY: all \ + site \ + clean + +site: clean + ssg + rssg + +preview: site + python3 -m http.server --directory $(OUTPUT_DIR) --bind 127.0.0.1 + +clean: + - rm -r $(OUTPUT_DIR) $(TEMPORARY_DIR) + +deploy: site + rsync -e ssh -avz --delete $(OUTPUT_DIR)/ $(REMOTE_HOST):$(REMOTE_DIR) + ssh $(REMOTE_HOST) chown -R www:www $(REMOTE_DIR) |