Fix "grep foo bar" in eshell

* lisp/eshell/em-unix.el (eshell-grep): Use the -H switch so that
we always get the file name, so that `M-x next-error' and friends
work (bug#22330).
This commit is contained in:
Lars Ingebrigtsen 2020-12-03 11:18:45 +01:00
parent 6422750b4f
commit 4b25ffd3b8

View file

@ -754,7 +754,7 @@ external command."
(eshell-stringify-list
(flatten-tree args)))
" "))
(cmd (format "%s -n %s"
(cmd (format "%s -nH %s"
(pcase command
("egrep" "grep -E")
("fgrep" "grep -F")