Hi, I'm forwarding a bug report filed in debian. Is this the expected behavior?
/tmp/greptest % dpkg -l | grep -r grep wtf:hello grep /tmp/greptest % dpkg -l | grep grep ii grep 2.21-1 amd64 GNU grep, egrep and fgrep grep -r takes the current dir as input instead of stdin. Regards, Santiago ----- Forwarded message from hha...@gmail.com ----- Date: Tue, 2 Dec 2014 21:38:51 +0200 From: hha...@gmail.com To: 414...@bugs.debian.org Subject: Bug#414168: Recursive grep even when content on stdin X-Mailer: Sylpheed 3.4.2 (GTK+ 2.24.22; amd64-portbld-freebsd9.3) Hello Since wheezy (grep 2.12-2) a patch like this has apparently been merged. I'm not seeing it documented on the man page. (Shouldn't it be?) This is undesirable for those of us who use shell aliases. For example, I use alias grep='grep -rI --exclude-dir=.svn' Try the following sequence of commands: mkdir /tmp/greptest cd /tmp/greptest echo hello grep > wtf alias grep='grep -r' dpkg -l | grep grep Expected results: ii grep 2.12-2 amd64 GNU grep, egrep and fgrep Actual results: wtf:hello grep It seems GREP_OPTIONS is special-cased, and I can move the switches there as a workaround. ----- End forwarded message ----- -- To UNSUBSCRIBE, email to debian-bugs-dist-requ...@lists.debian.org with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org