287 |
(": \\(.+\\): \\(?:Permission denied\\|No such \\(?:file or directory\\|device or address\\)\\)$" |
(": \\(.+\\): \\(?:Permission denied\\|No such \\(?:file or directory\\|device or address\\)\\)$" |
288 |
1 grep-error-face) |
1 grep-error-face) |
289 |
;; remove match from grep-regexp-alist before fontifying |
;; remove match from grep-regexp-alist before fontifying |
290 |
("^Grep started.*" (0 '(face nil message nil help-echo nil mouse-face nil) t)) |
("^Grep started.*" |
291 |
|
(0 '(face nil message nil help-echo nil mouse-face nil) t)) |
292 |
("^Grep finished \\(?:(\\(matches found\\))\\|with \\(no matches found\\)\\).*" |
("^Grep finished \\(?:(\\(matches found\\))\\|with \\(no matches found\\)\\).*" |
293 |
(0 '(face nil message nil help-echo nil mouse-face nil) t) |
(0 '(face nil message nil help-echo nil mouse-face nil) t) |
294 |
(1 compilation-info-face nil t) |
(1 compilation-info-face nil t) |
518 |
|
|
519 |
;; Setting process-setup-function makes exit-message-function work |
;; Setting process-setup-function makes exit-message-function work |
520 |
;; even when async processes aren't supported. |
;; even when async processes aren't supported. |
521 |
(let ((compilation-process-setup-function 'grep-process-setup) |
(compilation-start (if (and grep-use-null-device null-device) |
522 |
(compilation-disable-input t)) |
(concat command-args " " null-device) |
523 |
(compilation-start (if (and grep-use-null-device null-device) |
command-args) |
524 |
(concat command-args " " null-device) |
'grep-mode nil highlight-regexp)) |
|
command-args) |
|
|
'grep-mode nil highlight-regexp))) |
|
525 |
|
|
526 |
;;;###autoload |
;;;###autoload |
527 |
(define-compilation-mode grep-mode "Grep" |
(define-compilation-mode grep-mode "Grep" |
531 |
grep-hit-face) |
grep-hit-face) |
532 |
(set (make-local-variable 'compilation-error-regexp-alist) |
(set (make-local-variable 'compilation-error-regexp-alist) |
533 |
grep-regexp-alist) |
grep-regexp-alist) |
534 |
|
(set (make-local-variable 'compilation-process-setup-function) |
535 |
|
'grep-process-setup) |
536 |
|
(set (make-local-variable 'compilation-disable-input) t) |
537 |
;; Set `font-lock-lines-before' to 0 to not refontify the previous |
;; Set `font-lock-lines-before' to 0 to not refontify the previous |
538 |
;; line where grep markers may be already removed. |
;; line where grep markers may be already removed. |
539 |
(set (make-local-variable 'font-lock-lines-before) 0)) |
(set (make-local-variable 'font-lock-lines-before) 0)) |