summaryrefslogtreecommitdiff
path: root/rst_setups.lua
diff options
context:
space:
mode:
Diffstat (limited to 'rst_setups.lua')
-rw-r--r--rst_setups.lua34
1 files changed, 34 insertions, 0 deletions
diff --git a/rst_setups.lua b/rst_setups.lua
index 1b2428a..917eebb 100644
--- a/rst_setups.lua
+++ b/rst_setups.lua
@@ -323,5 +323,39 @@ function optional_setups.danger ()
end
+function optional_setups.citations ()
+ local cit = [[
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Citations %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\setupbibtex[database=\jobname]
+]]
+
+
+ return cit
+end
+
+function optional_setups.citator ()
+ local cit = [[
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+% Citator Options %
+%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
+\usemodule[citator]
+\loadbibdb{\jobname.bib}
+\setupcitator[sortmode=authoryear]
+\setupcite[mainmode=authoryear]
+
+\startbuffer[bibliography]
+\chapter{References}
+\setupbodyfont[small]
+\bibbykey{shorthand}{all}{author}
+\stopbuffer
+
+\prependtoks \getbuffer[bibliography] \to \everystoptext
+]]
+
+ return cit
+end
+
return optional_setups