47 lines
1.4 KiB
EmacsLisp
47 lines
1.4 KiB
EmacsLisp
;; build.el — org-publish configuration for personal site
|
|
(require 'org)
|
|
(require 'ox-publish)
|
|
(require 'ox-html)
|
|
|
|
(setq org-publish-use-timestamps-flag nil
|
|
org-export-with-broken-links t
|
|
org-html-validation-link nil
|
|
org-html-head-include-default-style nil
|
|
org-html-head-include-scripts nil)
|
|
|
|
(setq site-nav
|
|
"<nav>
|
|
<a href=\"/\">Home</a>
|
|
<a href=\"/about.html\">About</a>
|
|
</nav>")
|
|
|
|
(setq org-publish-project-alist
|
|
`(("site-pages"
|
|
:base-directory "./content"
|
|
:base-extension "org"
|
|
:publishing-directory "./public"
|
|
:recursive t
|
|
:publishing-function org-html-publish-to-html
|
|
:html-head-include-default-style nil
|
|
:html-head-include-scripts nil
|
|
:html-head "<link rel=\"stylesheet\" href=\"/style.css\"><script src=\"/animation.js\" defer></script>"
|
|
:html-preamble ,site-nav
|
|
:html-postamble nil
|
|
:with-author nil
|
|
:with-creator nil
|
|
:with-timestamps nil
|
|
:section-numbers nil
|
|
:with-toc nil)
|
|
|
|
("site-static"
|
|
:base-directory "./static"
|
|
:base-extension "css\\|js\\|png\\|jpg\\|jpeg\\|gif\\|svg\\|ico\\|woff2\\|woff\\|ttf"
|
|
:publishing-directory "./public"
|
|
:recursive t
|
|
:publishing-function org-publish-attachment)
|
|
|
|
("site"
|
|
:components ("site-pages" "site-static"))))
|
|
|
|
(org-publish "site" t)
|