Last active
July 23, 2021 19:48
-
-
Save bdarcus/5dd05ce983377a98bc086173f9c5b860 to your computer and use it in GitHub Desktop.
flatten org-cite-supported-styles
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; https://github.com/jkitchin/org-ref/issues/885#issuecomment-885682807 | |
;; doesn't currently handle the nil style correctly | |
(defun oc-bibtex-actions--simple-styles (&optional targets) | |
(let ((styles (org-cite-supported-styles targets))) | |
(cl-loop for group in styles append | |
(let ((main (pop group))) | |
(when (string= "nil" (car main)) (setf (car main) "")) | |
(append (list (car main)) | |
(cl-loop for rest in group collect | |
;; needs to remove "/nil" | |
(format "%s/%s" | |
(car main) | |
(car (cdr rest))))))))) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment