Public bug reported:

Binary package hint: grep

A common user error pattern is to call a recursive grep and miss off the
trailing '.' for current directory. This causes grep to wait
indefinitely for stdin, but users will presume it is just taking a long
time to search and will leave it running

$ grep -r PATTERN
...
...
...<indefinite pause>

This is on Ubuntu karmic running the latest GNU grep 2.5.4

Contrastingly, on a Apple Mac running OS X and grep (GNU grep) 2.5.1 a
helpful warning is printed in this case which immediately guides the
user to their mistake

$ grep -r PATTERN
grep: warning: recursive search of stdin

I presume this is a custom patch that has been applied to the grep
binary that ships with OSX (rather than a warning message that has been
purposefully removed), therefore I suggest this warning message is added
to the default code base.

ProblemType: Bug
Architecture: i386
Date: Wed Oct 21 15:49:26 2009
DistroRelease: Ubuntu 9.10
Package: grep 2.5.4-4
ProcEnviron:
 SHELL=/bin/bash
 PATH=(custom, user)
 LANG=en_GB.UTF-8
ProcVersionSignature: Ubuntu 2.6.31-14.48-generic
SourcePackage: grep
Uname: Linux 2.6.31-14-generic i686

** Affects: grep
     Importance: Unknown
         Status: Unknown

** Affects: grep (Ubuntu)
     Importance: Undecided
         Status: New


** Tags: apport-bug i386

-- 
grep does not print warning when recursively grepping stdin
https://bugs.launchpad.net/bugs/457277
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.

-- 
ubuntu-bugs mailing list
ubuntu-bugs@lists.ubuntu.com
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs

Reply via email to