commit 6abdc720032cacb546f8ccf0c05f41c6f4af9659
parent a48063f667146c2768ab119d00cfa60bf4ef70c1
Author: Vincent Demeester <vincent@sbr.pm>
Date: Thu, 5 May 2022 21:11:40 +0200
www: update some function and Makefile
Signed-off-by: Vincent Demeester <vincent@sbr.pm>
Diffstat:
4 files changed, 13 insertions(+), 2 deletions(-)
diff --git a/Makefile b/Makefile
@@ -87,6 +87,10 @@ clean-www:
-rm -rvf *.elc
-rm -rv ~/.org-timestamps/*
+.PHONY: www
+www:
+ (cd www; make)
+
# Documentation build and publishing
.PHONY: update-docs
update-docs:
diff --git a/www/Makefile b/www/Makefile
@@ -1,3 +1,5 @@
+all: build
+
build:
make -C vincent.demeester.fr build
diff --git a/www/vincent.demeester.fr/Makefile b/www/vincent.demeester.fr/Makefile
@@ -48,11 +48,11 @@ all: build
.PHONY: build
-build: publish.el publish-common.el build-articles
+build: lib/publish.el lib/publish-common.el build-articles
@echo "Publishing... with current Emacs configurations."
${EMACS} --debug-init --batch --directory $(DOTEMACS)/lisp/ --directory $(DOTEMACS)/lisp/vorg/ \
--load lib/publish-common.el --load lib/publish.el \
- --funcall org-publish-all
+ --funcall publish
.PHONY: build-articles
build-articles: $(NOTES)
diff --git a/www/vincent.demeester.fr/lib/publish.el b/www/vincent.demeester.fr/lib/publish.el
@@ -134,5 +134,10 @@
:recursive t)
("all" :components ("posts" "about" "index" "articles" "articles-assets" "css" "images" "assets" "legacy" "posts-rss"))))
+(defun publish ()
+ "Build vincent.demeester.fr website"
+ (delete-directory (expand-file-name "~/.org-timestamps") t)
+ (org-publish-all))
+
(provide 'publish)
;;; publish.el ends here