summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorfpi2020-02-27 10:20:34 +0100
committerfpi2020-02-27 10:53:04 +0100
commitbcaee90f36224e54271cc51a349007de267ead70 (patch)
treeb1cc31b39c8e3ff2c2f584905cde38cc2db6d3cf
parentChange to new gpg encryption key (diff)
Add a function to copy the doi from crossref-lookup
Diffstat (limited to '')
-rw-r--r--emacs-init.org9
1 files changed, 9 insertions, 0 deletions
diff --git a/emacs-init.org b/emacs-init.org
index 7cdb1b9..3320179 100644
--- a/emacs-init.org
+++ b/emacs-init.org
@@ -2075,6 +2075,15 @@ pdf if available."
(org-demote)
(buffer-substring (point-min) (point-max)))))
#+end_src
+Here's a function to easily copy a doi from the results of =crossref-lookup=.
+#+begin_src emacs-lisp
+(defun fpi/biblio-get-doi ()
+ (interactive)
+ (let ((doi (alist-get 'doi (cdr (biblio--selection-metadata-at-point)))))
+ (kill-new doi)
+ (message "Copied doi %s" doi)))
+(define-key biblio-selection-mode-map "d" #'fpi/biblio-get-doi)
+#+end_src
*** Todo settings
- WAITING tasks are waiting on the completion of other tasks
- NEXT tasks can be picked up