X-Git-Url: http://47.100.26.94:8080/?a=blobdiff_plain;ds=sidebyside;f=Makefile;h=0797b2db0d4b1eeee7b8470fa171aaf54e42186e;hb=72823b6c34e4e8f875a66a6370771276f28f9946;hp=b8a0e31d121356ebb3c79457b4525250c6c63458;hpb=a1e8b148970121c8f944f5abb2b85cca59090366;p=blog.git diff --git a/Makefile b/Makefile index b8a0e31..0797b2d 100644 --- a/Makefile +++ b/Makefile @@ -1,15 +1,29 @@ ## Makefile to export org in blog file to html emacs ?= emacs -OUTDIR := "" +OUTDIR := FORCE := "no" +BLOGDIR := $(PWD) all: $(emacs) -Q --script blog.el $(OUTDIR) $(FORCE) +# used for automation on server update: - git pull - $(emacs) -Q --script blog.el $(OUTDIR) + git pull && $(emacs) -Q --script blog.el "~/www/html" "true" + +publish: + $(emacs) -Q --batch -l my-publish.el index.org \ + --eval '(setq debug-on-error t)' \ + --eval '(blog-setup-project-alist "$(BLOGDIR)" "$(OUTDIR)")' \ + --eval '(org-publish-current-project)' + +# test will force publishing all files in the porject +test: + $(emacs) -Q --batch -l my-publish.el index.org \ + --eval '(setq debug-on-error t)' \ + --eval '(blog-setup-project-alist "$(BLOGDIR)")' \ + --eval '(org-publish-current-project t)' clean: rm -rf _site/*