Default the grep commands to skip directories
* lisp/progmodes/grep.el (grep-compute-defaults): Skip directories (bug#23590).
This commit is contained in:
parent
c842bd993f
commit
0ab67a65f5
1 changed files with 9 additions and 4 deletions
|
@ -703,10 +703,15 @@ The value depends on `grep-command', `grep-template',
|
|||
(let ((grep-options
|
||||
(concat (if grep-use-null-device "-n" "-nH")
|
||||
(if grep-use-null-filename-separator " --null")
|
||||
(if (grep-probe grep-program
|
||||
`(nil nil nil "-e" "foo" ,null-device)
|
||||
nil 1)
|
||||
" -e"))))
|
||||
(when (grep-probe grep-program
|
||||
`(nil nil nil "--directories=skip" "foo"
|
||||
,null-device)
|
||||
nil 1)
|
||||
" --directories=skip")
|
||||
(when (grep-probe grep-program
|
||||
`(nil nil nil "-e" "foo" ,null-device)
|
||||
nil 1)
|
||||
" -e"))))
|
||||
(unless grep-command
|
||||
(setq grep-command
|
||||
(format "%s %s %s " grep-program
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue