74 |
:version "21.4" |
:version "21.4" |
75 |
:group 'grep) |
:group 'grep) |
76 |
|
|
77 |
|
;;;###autoload |
78 |
(defcustom grep-command nil |
(defcustom grep-command nil |
79 |
"The default grep command for \\[grep]. |
"The default grep command for \\[grep]. |
80 |
If the grep program used supports an option to always include file names |
If the grep program used supports an option to always include file names |
101 |
(other :tag "Not Set" auto-detect)) |
(other :tag "Not Set" auto-detect)) |
102 |
:group 'grep) |
:group 'grep) |
103 |
|
|
104 |
|
;;;###autoload |
105 |
(defcustom grep-find-command nil |
(defcustom grep-find-command nil |
106 |
"The default find command for \\[grep-find]. |
"The default find command for \\[grep-find]. |
107 |
The default value of this variable is set up by `grep-compute-defaults'; |
The default value of this variable is set up by `grep-compute-defaults'; |
225 |
Notice that using \\[next-error] or \\[compile-goto-error] modifies |
Notice that using \\[next-error] or \\[compile-goto-error] modifies |
226 |
`complation-last-buffer' rather than `grep-last-buffer'.") |
`complation-last-buffer' rather than `grep-last-buffer'.") |
227 |
|
|
228 |
|
;;;###autoload |
229 |
(defvar grep-regexp-alist |
(defvar grep-regexp-alist |
230 |
'(("^\\(.+?\\)[:( \t]+\ |
'(("^\\(.+?\\)[:( \t]+\ |
231 |
\\([0-9]+\\)\\([.:]?\\)\\([0-9]+\\)?\ |
\\([0-9]+\\)\\([.:]?\\)\\([0-9]+\\)?\ |
261 |
"Additional things to highlight in grep output. |
"Additional things to highlight in grep output. |
262 |
This gets tacked on the end of the generated expressions.") |
This gets tacked on the end of the generated expressions.") |
263 |
|
|
264 |
|
;;;###autoload |
265 |
(defvar grep-program |
(defvar grep-program |
266 |
;; Currently zgrep has trouble. It runs egrep instead of grep, |
;; Currently zgrep has trouble. It runs egrep instead of grep, |
267 |
;; and it doesn't pass along long options right. |
;; and it doesn't pass along long options right. |
276 |
"The default grep program for `grep-command' and `grep-find-command'. |
"The default grep program for `grep-command' and `grep-find-command'. |
277 |
This variable's value takes effect when `grep-compute-defaults' is called.") |
This variable's value takes effect when `grep-compute-defaults' is called.") |
278 |
|
|
279 |
|
;;;###autoload |
280 |
(defvar find-program "find" |
(defvar find-program "find" |
281 |
"The default find program for `grep-find-command'. |
"The default find program for `grep-find-command'. |
282 |
This variable's value takes effect when `grep-compute-defaults' is called.") |
This variable's value takes effect when `grep-compute-defaults' is called.") |
283 |
|
|
284 |
|
;;;###autoload |
285 |
(defvar grep-find-use-xargs nil |
(defvar grep-find-use-xargs nil |
286 |
"Whether \\[grep-find] uses the `xargs' utility by default. |
"Whether \\[grep-find] uses the `xargs' utility by default. |
287 |
|
|
291 |
This variable's value takes effect when `grep-compute-defaults' is called.") |
This variable's value takes effect when `grep-compute-defaults' is called.") |
292 |
|
|
293 |
;; History of grep commands. |
;; History of grep commands. |
294 |
|
;;;###autoload |
295 |
(defvar grep-history nil) |
(defvar grep-history nil) |
296 |
|
;;;###autoload |
297 |
(defvar grep-find-history nil) |
(defvar grep-find-history nil) |
298 |
|
|
299 |
|
;;;###autoload |
300 |
(defun grep-process-setup () |
(defun grep-process-setup () |
301 |
"Setup compilation variables and buffer for `grep'. |
"Setup compilation variables and buffer for `grep'. |
302 |
Set up `compilation-exit-message-function' and run `grep-setup-hook'." |
Set up `compilation-exit-message-function' and run `grep-setup-hook'." |
312 |
(cons msg code)))) |
(cons msg code)))) |
313 |
(run-hooks 'grep-setup-hook)) |
(run-hooks 'grep-setup-hook)) |
314 |
|
|
315 |
|
;;;###autoload |
316 |
(defun grep-compute-defaults () |
(defun grep-compute-defaults () |
317 |
(unless (or (not grep-use-null-device) (eq grep-use-null-device t)) |
(unless (or (not grep-use-null-device) (eq grep-use-null-device t)) |
318 |
(setq grep-use-null-device |
(setq grep-use-null-device |
458 |
grep-regexp-alist)) |
grep-regexp-alist)) |
459 |
|
|
460 |
;; This is a copy of find-tag-default from etags.el. |
;; This is a copy of find-tag-default from etags.el. |
461 |
|
;;;###autoload |
462 |
(defun grep-tag-default () |
(defun grep-tag-default () |
463 |
(save-excursion |
(save-excursion |
464 |
(while (looking-at "\\sw\\|\\s_") |
(while (looking-at "\\sw\\|\\s_") |