diff options
| author | Dmitry Gutov | 2015-06-28 04:29:03 +0300 |
|---|---|---|
| committer | Dmitry Gutov | 2015-06-28 04:29:03 +0300 |
| commit | a1dde6b50fb8601b2a3ac333cc43569622a18500 (patch) | |
| tree | 197452afc0ee4e3047c95e61f4f8ce4138ea300c | |
| parent | 9b4b4a8355506a0253d8a4943e0a9aa87f9e92eb (diff) | |
| download | emacs-a1dde6b50fb8601b2a3ac333cc43569622a18500.tar.gz emacs-a1dde6b50fb8601b2a3ac333cc43569622a18500.zip | |
Put "--color" before the other options in grep-command
* lisp/progmodes/grep.el (grep-compute-defaults): Put "--color"
before the other options in grep-command (bug#20912).
| -rw-r--r-- | lisp/progmodes/grep.el | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lisp/progmodes/grep.el b/lisp/progmodes/grep.el index e20e5bd4c40..639d8d93652 100644 --- a/lisp/progmodes/grep.el +++ b/lisp/progmodes/grep.el | |||
| @@ -579,7 +579,7 @@ This function is called from `compilation-filter-hook'." | |||
| 579 | " -e")))) | 579 | " -e")))) |
| 580 | (unless grep-command | 580 | (unless grep-command |
| 581 | (setq grep-command | 581 | (setq grep-command |
| 582 | (format "%s %s %s " grep-program grep-options | 582 | (format "%s %s %s " grep-program |
| 583 | (or | 583 | (or |
| 584 | (and grep-highlight-matches | 584 | (and grep-highlight-matches |
| 585 | (grep-probe grep-program | 585 | (grep-probe grep-program |
| @@ -587,7 +587,8 @@ This function is called from `compilation-filter-hook'." | |||
| 587 | nil 1) | 587 | nil 1) |
| 588 | (if (eq grep-highlight-matches 'always) | 588 | (if (eq grep-highlight-matches 'always) |
| 589 | "--color=always" "--color")) | 589 | "--color=always" "--color")) |
| 590 | "")))) | 590 | "") |
| 591 | grep-options))) | ||
| 591 | (unless grep-template | 592 | (unless grep-template |
| 592 | (setq grep-template | 593 | (setq grep-template |
| 593 | (format "%s <X> <C> %s <R> <F>" grep-program grep-options))) | 594 | (format "%s <X> <C> %s <R> <F>" grep-program grep-options))) |