From 791581b0303a2310dcc983c17a8c1a73e1a4667e Mon Sep 17 00:00:00 2001 From: John Kitchin Date: Fri, 12 Dec 2014 07:20:57 -0500 Subject: [PATCH] give option for which bibliography to save doi in --- doi-utils.org | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/doi-utils.org b/doi-utils.org index fe64cff..5e539db 100644 --- a/doi-utils.org +++ b/doi-utils.org @@ -552,11 +552,14 @@ It may be you are in some other place when you want to add a bibtex entry. This #+BEGIN_SRC emacs-lisp :tangle doi-utils.el (defun doi-utils-add-bibtex-entry-from-doi (doi bibfile) - "add entry to end a file in `org-ref-default-bibliography'." + "add entry to end of a file in `org-ref-default-bibliography' or in the current directory ending with .bib." (interactive (list (read-string "DOI: ") - (ido-completing-read "Bibfile: " org-ref-default-bibliography))) + (ido-completing-read + "Bibfile: " + (append org-ref-default-bibliography + (f-entries "." (lambda (f) (f-ext? f "bib"))))))) (find-file bibfile) (goto-char (point-min)) (if (search-forward doi nil t) -- 2.39.2