bibtex: Fix `org-bibtex-goto-citation'
* contrib/lisp/ox-bibtex.el (org-bibtex-goto-citation): Fix `org-bibtex-goto-citation'. Reported-by: Eric S Fraga <e.fraga@ucl.ac.uk> <http://lists.gnu.org/r/emacs-orgmode/2020-04/msg00383.html>
This commit is contained in:
parent
178e47a0c5
commit
7cdc023f88
|
@ -162,10 +162,8 @@ to `org-bibtex-citation-p' predicate."
|
||||||
(let ((citation (or citation (completing-read "Citation: " (obe-citations)))))
|
(let ((citation (or citation (completing-read "Citation: " (obe-citations)))))
|
||||||
(find-file (or org-bibtex-file
|
(find-file (or org-bibtex-file
|
||||||
(error "`org-bibtex-file' has not been configured")))
|
(error "`org-bibtex-file' has not been configured")))
|
||||||
(goto-char (point-min))
|
(let ((position (org-find-property "CUSTOM_ID" citation)))
|
||||||
(when (re-search-forward (format " :CUSTOM_ID: %s" citation) nil t)
|
(and position (progn (goto-char position) t)))))
|
||||||
(outline-previous-visible-heading 1)
|
|
||||||
t)))
|
|
||||||
|
|
||||||
(let ((jump-fn (car (cl-remove-if-not #'fboundp '(ebib org-bibtex-goto-citation)))))
|
(let ((jump-fn (car (cl-remove-if-not #'fboundp '(ebib org-bibtex-goto-citation)))))
|
||||||
(org-add-link-type "cite" jump-fn))
|
(org-add-link-type "cite" jump-fn))
|
||||||
|
|
Loading…
Reference in New Issue