emacs-diffs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Emacs-diffs] master 6d020ec: Override 'grep --color=always'


From: Dmitry Gutov
Subject: [Emacs-diffs] master 6d020ec: Override 'grep --color=always'
Date: Wed, 03 Jun 2015 23:46:51 +0000

branch: master
commit 6d020ecd8951244296ebefc04d15eb10781bb846
Author: Dmitry Gutov <address@hidden>
Commit: Dmitry Gutov <address@hidden>

    Override 'grep --color=always'
    
    * lisp/progmodes/xref.el (xref-collect-matches):
    Override --color=always in grep-find-template.
---
 lisp/progmodes/xref.el |    9 +++++++--
 1 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/lisp/progmodes/xref.el b/lisp/progmodes/xref.el
index f786d4e..89a9cf5 100644
--- a/lisp/progmodes/xref.el
+++ b/lisp/progmodes/xref.el
@@ -749,8 +749,13 @@ tools are used, and when."
   (require 'semantic/fw)
   (grep-compute-defaults)
   (defvar grep-find-template)
-  (let* ((grep-find-template (replace-regexp-in-string "-e " "-E "
-                                                       grep-find-template t t))
+  (let* ((grep-find-template
+          (replace-regexp-in-string
+           ;; Override the use ot '--color=always' on MS-Windows.
+           "--color=always" ""
+           (replace-regexp-in-string "-e " "-E "
+                                     grep-find-template t t)
+           t t))
          (command (rgrep-default-command (xref--regexp-to-extended regexp)
                                          "*.*" dir))
          (orig-buffers (buffer-list))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]