Function: reftex-extract-bib-file
reftex-extract-bib-file is a byte-compiled function defined in
reftex-cite.el.gz.
Signature
(reftex-extract-bib-file ALL &optional MARKED COMPLEMENT)
Documentation
Limit FOUND-LIST with more regular expressions.
Source Code
;; Defined in /usr/src/emacs/lisp/textmodes/reftex-cite.el.gz
(defun reftex-extract-bib-file (all &optional marked complement)
"Limit FOUND-LIST with more regular expressions."
(let ((file (read-file-name "File to create: ")))
(find-file-other-window file)
(if (> (buffer-size) 0)
(unless (yes-or-no-p
(format "Overwrite non-empty file %s? " file))
(error "Abort")))
(erase-buffer)
(setq all (delq nil
(mapcar
(lambda (x)
(if marked
(if (or (and (assoc x marked) (not complement))
(and (not (assoc x marked)) complement))
(cdr (assoc "&entry" x))
nil)
(cdr (assoc "&entry" x))))
all)))
(insert (mapconcat #'identity all "\n\n"))
(save-buffer)
(goto-char (point-min))))