Function: reftex-grep-document

reftex-grep-document is an autoloaded, interactive and byte-compiled function defined in reftex-global.el.gz.

Signature

(reftex-grep-document GREP-CMD)

Documentation

Run grep query through all files related to this document.

With prefix arg, force to rescan document. No active TAGS table is required.

Key Bindings

Source Code

;; Defined in /usr/src/emacs/lisp/textmodes/reftex-global.el.gz
;;;###autoload
(defun reftex-grep-document (grep-cmd)
  "Run grep query through all files related to this document.
With prefix arg, force to rescan document.
No active TAGS table is required."

  (interactive
   (list (read-from-minibuffer "Run grep on document (like this): "
                               reftex-grep-command nil nil
                               'reftex-grep-history)))
  (reftex-access-scan-info current-prefix-arg)
  (let* ((files  (reftex-all-document-files t))
         (cmd    (format
                  "%s %s" grep-cmd
                  (mapconcat #'identity files " "))))
    (grep cmd)))