-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.el
37 lines (32 loc) · 1.4 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
;;; build.el --- Build book.pdf non-interactively -*- lexical-binding: t -*-
;;; Commentary:
;;; This is used to build my PhD thesis from scripts (e.g. to create a diffed version).
;;; Code:
(package-initialize)
(require 'org)
(require 'oc-csl)
(require 'ox)
(setq org-latex-classes '(("book"
"\\documentclass[]{scrbook}"
("\\chapter{%s}" . "\\addchap{%s}")
("\\section{%s}" . "\\addsec{%s}")
("\\subsection{%s}" . "\\subsection*{%s}")
("\\subsubsection{%s}" . "\\subsubsection*{%s}")))
org-latex-caption-above nil
org-latex-src-block-backend 'minted
org-latex-minted-options '(("linenos" . "true")
("breaklines" . "true"))
org-latex-prefer-user-labels t
org-latex-subtitle-format "\\subtitle{%s}"
org-latex-subtitle-separate t)
(add-to-list
'org-export-smart-quotes-alist
'("en-gb" (primary-opening :utf-8 "“" :html "“" :latex "``" :texinfo "``")
(primary-closing :utf-8 "”" :html "”" :latex "''" :texinfo "''")
(secondary-opening :utf-8 "‘" :html "‘" :latex "`" :texinfo "`")
(secondary-closing :utf-8 "’" :html "’" :latex "'" :texinfo "'")
(apostrophe :utf-8 "’" :html "’")))
(find-file "book.org")
(org-latex-export-to-latex)
(provide 'build)
;;; build.el ends here