File: ol-bibtex.el.html
This file implements links to database entries in BibTeX files. Instead of defining a special link prefix, it uses the normal file links combined with a custom search mechanism to find entries by reference key. And it constructs a nice description tag for the link that contains the author name, the year and a short title.
It also stores detailed information about the entry so that capture templates can access and enter this information easily.
The available properties for each entry are listed here:
:author :publisher :volume :pages
:editor :url :number :journal
:title :year :series :address
:booktitle :month :annote :abstract
:key :btype
Here is an example of a capture template that use some of this information (:author :year :title :journal :pages):
(setq org-capture-templates
'((?b "* READ %?\\n\\n%a\\n\\n%:author (%:year): %:title\\n \\
In %:journal, %:pages.")))
Let's say you want to capture this BibTeX entry:
@Article{dolev83,
author = {Danny Dolev and Andrew C. Yao},
title = {On the security of public-key protocols},
journal = {IEEE Transaction on Information Theory},
year = 1983,
volume = 2,
number = 29,
pages = {198--208},
month = {Mars}
}
M-x org-capture on this entry will produce this buffer:
=====================================================================
* READ <== [point here]
[[file:file.bib::dolev83][Dolev & Yao 1983: security of public key protocols]]
Danny Dolev and Andrew C. Yao (1983): On the security of public-key protocols
In IEEE Transaction on Information Theory, 198--208.
=====================================================================
Additionally, the following functions are now available for storing bibtex entries within Org documents.
- Run org-bibtex to export the current file to a .bib.
- Run org-bibtex-check or org-bibtex-check-all to check and
fill in missing field of either the current, or all headlines
- Run org-bibtex-create to add a bibtex entry
- Use org-bibtex-read to read a bibtex entry after point or in
the active region, then call org-bibtex-write in a .org file to
insert a heading for the read bibtex entry
- All BibTeX information is taken from the document compiled by
Andrew Roberts from the BibTeX manual, available at
https://www.andy-roberts.net/res/writing/latex/bibentries.pdf
Defined variables (14)
org-bibtex-autogen-keys | Set to a truth value to use ‘bibtex-generate-autokey’ to generate keys. |
org-bibtex-entries | List to hold parsed bibtex entries. |
org-bibtex-export-arbitrary-fields | When converting to bibtex allow fields not defined in ‘org-bibtex-fields’. |
org-bibtex-fields | BibTeX fields with descriptions. |
org-bibtex-headline-format-function | Function returning the headline text for ‘org-bibtex-write’. |
org-bibtex-inherit-tags | Controls whether inherited tags are converted to bibtex keywords. |
org-bibtex-key-property | Property that holds the bibtex key. |
org-bibtex-no-export-tags | List of tag(s) that should not be converted to keywords. |
org-bibtex-prefix | Optional prefix for all bibtex property names. |
org-bibtex-tags | List of tag(s) that should be added to new bib entries. |
org-bibtex-tags-are-keywords | Convert the value of the keywords field to tags and vice versa. |
org-bibtex-treat-headline-as-title | Treat headline text as title if title property is absent. |
org-bibtex-type-property-name | Property in which to store bibtex entry type (e.g., article). |
org-bibtex-types | BibTeX entry types with required and optional parameters. |
Defined functions (23)
org-bibtex | (FILENAME) |
org-bibtex-ask | (FIELD) |
org-bibtex-autokey | () |
org-bibtex-check | (&optional OPTIONAL) |
org-bibtex-check-all | (&optional OPTIONAL) |
org-bibtex-create | (&optional ARG NONEW) |
org-bibtex-create-in-current-entry | (&optional ARG) |
org-bibtex-export-to-kill-ring | () |
org-bibtex-fleshout | (TYPE &optional OPTIONAL) |
org-bibtex-get | (PROPERTY) |
org-bibtex-headline | () |
org-bibtex-import-from-file | (FILE) |
org-bibtex-open | (PATH ARG) |
org-bibtex-put | (PROPERTY VALUE &optional INSERT-RAW) |
org-bibtex-read | () |
org-bibtex-read-buffer | (BUFFER) |
org-bibtex-read-file | (FILE) |
org-bibtex-search | (STRING) |
org-bibtex-store-link | () |
org-bibtex-write | (&optional NOINDENT) |
org-bibtex-yank | () |
org-create-file-search-in-bibtex | () |
org-execute-file-search-in-bibtex | (S) |