diff --git a/emacs/.config/doom/config.org b/emacs/.config/doom/config.org index 2f53fb7..69bd74a 100644 --- a/emacs/.config/doom/config.org +++ b/emacs/.config/doom/config.org @@ -258,7 +258,7 @@ We start by simply defining the standard headers used by the three files. These :tools ;;ansible - biblio ; Writes a PhD for you (citation needed) + biblio ; Writes a PhD for you (citation needed) ;;collab ; buffers with friends ;;debugger ; FIXME stepping through code, to help you add bugs ;;direnv @@ -525,7 +525,7 @@ Adding the "#+category: " tag improves the Org Agenda View for tasks captured in :if-new (file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: ${title}\n#+category: ${title}\n") :unnarrowed t) ("m" "Meeting Templates") - ("mm" "Besprechung Masterarbeit" plain + ("mm" "Meeting Masterarbeit" plain "* Aktueller Stand\n\n* Offene Fragen\n\n* TODOs\n" :if-new (file+head "%<%Y%m%d%H%M%S>-${slug}.org" "#+title: Masterarbeitsbesprechung ${title}\n#+category: Masterarbeit\n") :unnarrowed t)))) @@ -543,7 +543,45 @@ Because the normal shortcut for `org-open-at-point` is quite cumbersome I want i (package! org-transclusion) #+end_src ** Bibliography -as per [[https://github.com/doomemacs/doomemacs/tree/master/modules/tools/biblio][Doom Emacs documentation]] the path to the .bib file needs to be defined +*** Enabling Zotero Links +Following [[https://www.riccardopinosio.com/blog/posts/zotero_notes_article.html#opening-zotero-pdf-from-org-roam][this guide]] we enable using zotero links with the following code #+begin_src emacs-lisp :tangle config.el -(setq! citar-bibliography '("~/org/biblio.bib")) +(after! org + :custom + (org-link-set-parameters "zotero" :follow + (lambda (zpath) + (browse-url + (format "zotero:%s" zpath))))) +#+end_src +*** Citar Config +**** Setting the Citar Bibliography +Following the [[https://github.com/doomemacs/doomemacs/tree/master/modules/tools/biblio][Doom Emacs documentation ]]we set the citar bibliography and notes paths +#+begin_src emacs-lisp :tangle config.el +(after! oc + (setq citar-bibliography '("~/org/biblio.bib")) + (setq citar-notes-paths '("~/org/org-roam/"))) +#+end_src +**** Citar Templates +Following the [[https://github.com/emacs-citar/citar#configuration][citar package documentation]] we modify the note template to contain the pdf link to Zotero +*NOTE:* This requires the a [[https://www.riccardopinosio.com/blog/posts/zotero_notes_article.html#opening-zotero-pdf-from-org-roam][specific Zotero Export Configuration]] +#+begin_src emacs-lisp :tangle config.el +(after! oc + (setq citar-templates + '((main . "${author editor:30%sn} ${date year issued:4} ${title:48}") + (suffix . " ${=key= id:15} ${=type=:12} ${tags keywords:*}") + (preview . "${author editor:%etal} (${year issued date}) ${title}, ${journal journaltitle publisher container-title collection-title}.\n") + (note . "Notes on ${author editor:%etal}, ${title}\npdf: ${file}")))) +#+end_src +**** Enable Zotero Link Support +In [[https://www.riccardopinosio.com/blog/posts/zotero_notes_article.html#citar][this tutorial]] I found the config for enabling Zotero Link Support through Citar +#+begin_src emacs-lisp :tangle config.el +(defadvice! riccardo/citar-file-trust-zotero (oldfun &rest r) + "Leave Zotero-generated file paths alone, especially zotero://..." + :around '(citar-file-open citar-file--find-files-in-dirs) + (cl-letf (((symbol-function 'file-exists-p) #'always) + ((symbol-function 'expand-file-name) (lambda (first &rest _) first))) + (apply oldfun r))) + +(after! citar + (add-to-list 'citar-file-open-functions '("pdf" . citar-file-open-external))) #+end_src