Skip to content

Instantly share code, notes, and snippets.

@bdarcus
Last active October 3, 2021 12:42
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save bdarcus/2645f99363fc47ddab2aae24c5d9e66c to your computer and use it in GitHub Desktop.
Save bdarcus/2645f99363fc47ddab2aae24c5d9e66c to your computer and use it in GitHub Desktop.
org-cite testing init, instructions
;; to test org-cite-new branch:
;;
;; 1. run 'make' from the org-mode repo wip-cite-new branch root
;;
;; 2. run ...
;;
;; ... this for basic citation testing:
;;
;; emacs -Q -l cite-init.el
;;
;; ... this, if you also want to test bibtex-actions org citation insertion,
;; make sure you have that repo downloaded and the 'org-cite'
;; branch checked out; then do:
;;
;; emacs -Q -l cite-init.el -l ../bibtex-actions/test/install.el -l ../bibtex-actions/test/bibtex-actions.el
;;
;;; Code:
(package-install 'use-package)
(setq native-comp-async-report-warnings-errors nil)
(let ((org-root "~/Code/org-mode"))
(when (file-directory-p org-root)
(dolist (dir '("../citeproc-el" "lisp" "contrib/lisp" "testing" "testing/lisp"))
(add-to-list 'load-path (expand-file-name dir org-root)))))
(setq org-latex-pdf-process '("latexmk -f -pdf -%latex -outdir=%o %f"))
(require 'oc-natbib)
(require 'oc-biblatex)
(require 'oc-csl)
(require 'oc-csl-activate)
(require 'ox)
(add-hook 'org-mode-hook
(lambda ()
(cursor-sensor-mode 1)
(org-cite-csl-activate-render-all)))
(setq org-cite-csl-styles-dir "~/.local/share/csl")
(setq org-cite-activate-processor 'csl-activate)
(setq org-cite-global-bibliography '("~/org/bib/test.bib"))
(provide 'cite-init)
;;; cite-init.el ends here
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment