hep-th.el
is a small Emacs tool for the hep-th people. In
particular, it helps you make reference lists in (La)TeX files; you
don't have to switch to a browser, go to SPIRES, copy the reference
entries, and paste that back into your tex source. All you have to do
is to type the arxiv number in Emacs. Then hep-th.el
will
do it all for you.
Suggestions for more useful features are most welcome.
~/elisp/hep-th.el
". Further, in your "~/.emacs
",
append the following lines:
;; hep-th.el settings (load-file (expand-file-name "~/elisp/hep-th.el")) (setq hep-th-default-bib-format 'latex) ; this changes the format of the bibl. data for "C-c h i" and "C-c h a". ; Possible options are 'latex, 'latex2, 'harvmac, and 'bibtex. (setq hep-th-default-arxiv-name "hep-th") ; If arxiv name is not provided (such as yymmnnn instead of ; hep-th/yymmnnn), this arxiv name is added. (setq hep-th-bib-uncomment-title nil) ; if t, uncomments the title in the bibl. data when they are inserted. (setq hep-th-use-arxiv.org-for-arxiv-number nil) ; if t, use arxiv.org instead of SPIRES HEP to browse a paper specified ; by an arxiv number arxiv-name/yymmnnn. (global-set-key "\C-chi" 'hep-th-insert-bib) (global-set-key "\C-cha" 'hep-th-append-bib) (global-set-key "\C-chs" 'hep-th-spires-query-from-minibuffer) (global-set-key "\C-chg" 'hep-th-browse-corresponding-paper) ; You can customize these key sequences to invoke commands. It may be a ; good idea to use hooks to avoid possible conflicts with the existing ; key bindings.
Type C-c h i, and enter the
arxiv number. You can omit the arxiv name, i.e. you may just type
"9407087
" instead of "hep-th/9407087
". The
format of the inserted bibliographic entry is controlled by the
variable hep-th-default-bib-format. To override this,
use C-u C-c h i
instead.
Type C-c h a, and enter the arxiv number (you can omit the arxiv name as before).
The format of the inserted bibliographic entry, and the place
where the bibliographic entry will be inserted depend on the value
of the variable hep-th-default-bib-format. If the value is
latex
or latex2
, the entry will be inserted in
the thebibliography
environment of the current file. If
the value is bibtex
, the entry will be inserted in the
BibTeX file. For the harvmac
format, this feature isn't
available, since hep-th.el doesn't know where to insert the entry.
To override hep-th-default-bib-format, use C-u
C-c h i instead.
When you use the bibtex
format, the BibTeX filename
is determined by the variable hep-th-bibtex-filename,
or by the \bibliography{}
command in the current
file.
Type C-c h g on an arxiv
number such as "hep-th/9407087
" to browse to the
corresponding paper webpage at SPIRES HEP. If the variable
hep-th-use-arxiv.org-for-arxiv-number is non-nil,
arxiv.org is used instead (this may be better for papers that has
just appeared, since a paper doesn't appear at
SPIRES HEP immediately after it appears at arxiv.org).
Type C-c h g on a citation
command such as "\cite{Seiberg:1994rs}
" (if the
variable hep-th-default-bib-format is set to
latex
, latex2
, or bibtex
)
or "\SeibergRS
" (harvmac
) to browse the
corresponding paper webpage at SPIRES HEP. To override
hep-th-bibtex-bib-format, use C-u
C-c h g instead.
For this to work, there should exist the corresponding entry in
the current TeX file (latex
, latex2
,
harvmac
) or in the BibTeX file (bibtex
),
in order to determine the arxiv number of the paper. The
bibliographic entry must contain the arxiv number data, which is
the case if you added the entry by C-c h
a.
Type C-c h s, and enter the search command. command and launches a web browser. If you want to specify more options, type C-u C-c h s instead.
You can type an arxiv number of the form "arxiv-name/yymmnnn" instead of a SPIRES HEP command. In this case, if the variable hep-th-use-arxiv.org-for-arxiv-number is non-nil, arxiv.org is used instead of SPIRES HEP.
Change the stuff in your ~/.emacs
(see INSTALLATION
above). For more customizable variables, read the elisp code.
At the first line of the tex file, insert:
% -*- hep-th-default-bib-format: bibtex; -*-Then the variable will be set when the file is opened. (Note that no apostrophe is necessary here.) You can set more than one variables as follows:
% -*- hep-th-default-bib-format: harvmac; hep-th-bib-uncomment-title t; -*-