-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.el
57 lines (47 loc) · 1.53 KB
/
build.el
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
;;; build --- build the documentation for publication -*- lexical-binding: t -*-
;;; Commentary:
;;; Code:
(require 'package)
(setq package-user-dir (expand-file-name "./.packages"))
(setq package-archives '(("melpa" . "https://melpa.org/packages/")
("elpa" . "https://elpa.gnu.org/packages/")))
(package-initialize)
(unless package-archive-contents
(package-refresh-contents))
(package-install 'htmlize)
(package-install 'reformatter)
(package-install 'color-theme-modern)
(require 'htmlize)
(require 'ox-publish)
(require 'font-lock)
(load-theme 'greiner t t)
(enable-theme 'greiner)
(global-font-lock-mode t)
(setq org-html-validation-link nil
org-html-head-include-scripts nil
org-html-include-default-style nil
org-src-fontify-natively t)
(setq org-publish-project-alist
'(("dotfiles-i3"
:components ("pages" "static"))
("pages"
:recursive t
:base-directory "./content"
:publishing-directory "./public"
:publishing-function org-html-publish-to-html
:with-author t
:with-creator nil
:with-toc t
:setion-numbers nil
:time-stamp-file nil)
("static"
:recursive t
:base-directory "./assets"
:base-extension "css\\|js\\|png\\|jpg\\|gif\\|pdf\\|mp3\\|ogg\\|swf"
:publishing-directory "./public/assets"
:publishing-function org-publish-attachment)))
;; Generate site
(org-publish-all t)
(message "Build completed")
(provide 'build)
;;; build.el ends here