summaryrefslogblamecommitdiff
path: root/publish.el
blob: e417892137e43c7132596680159f5a6101217730 (plain) (tree)
1
2
3
4
5
6
7
8
9
10
11
12



                     







                                                                               













                                                                                        
                                        
                            






                                                     
              





                                                    
                                                          
(package-initialize)

(require 'ox-publish)

(defun me/html-preamble (plist)
  (with-temp-buffer
    (insert-file-contents "../html-templates/preamble.html") (buffer-string)))

(defun me/html-postamble (plist)
  (with-temp-buffer
    (insert-file-contents "../html-templates/postamble.html") (buffer-string)))

(setq org-publish-project-alist
      '(("pages"
         :base-directory "pages"
         :base-extension "org"
         :publishing-directory "site"
         :recursive t
         :publishing-function org-html-publish-to-html
	 :html-head "<link rel='stylesheet' href='../css/default.css' type='text/css'/>"
	 :html-prefer-user-labels t
	 :html-mathjax-options nil
	 :html-mathjax-template ""
	 :with-toc nil
	 :section-numbers nil
	 :html-self-link-headlines t
	 :html-preamble me/html-preamble
	 :html-postamble nil
	 )
	("pages-html"
	 :base-directory "pages"
	 :base-extension "html"
	 :publishing-directory "site"
	 :recursive t
	 :publishing-function org-publish-attachment)
	("css"
         :base-directory "css"
         :base-extension "css"
         :publishing-directory "site/css"
         :publishing-function org-publish-attachment
         :recursive t
	 )
        ("all" :components ("pages" "pages-html" "css"))))