[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Grep --directories option
From: |
Patrick Strasser |
Subject: |
Re: Grep --directories option |
Date: |
Sat, 31 May 2003 02:06:50 +0200 |
User-agent: |
Internet Messaging Program (IMP) 4.0-cvs |
Quoting Jeff Bailey <jbailey@nisa.net>:
> On Fri, May 30, 2003 at 01:58:14PM -0700, Paul Eggert wrote:
>
> > This is simple and portable, and it's more useful than the current
> > behavior. The new behavior would conform to POSIX, since POSIX
> > requires that the input files must be text files; directories are not
> > text files, so GNU grep can do what it likes with them.
>
> I don't have my copy of Posix handy - Is there a rule saying that
> directories cannot be textfiles? It's certainly reasonable in the Hurd
> that they might be both.
If I understand diretory semantics in the Hurd right, the directory is meant
as directory only with a trailing slash, and as file if only called with
the name without slash.
So `grep foo bar/` would search for files with contents foo in the directory
bar, and `grep foo bar` would search for files with parts of their names
containig foo. So --directory would be not significant, at least not for
first order. Greping directories as files would then be of course not
recoursive.
Please correct me if I'm wrong; mayby I'm completely mistaken and mix things
up.
Patrick
--
Engineers motto: cheap, good, fast: choose any two
Patrick Strasser <past at sbox dot tugraz dot at>
Student of Telematik, Techn. University Graz, Austria
- Re: Grep --directories option, (continued)
- Re: Grep --directories option, Stepan Kasal, 2003/05/30
- Re: Grep --directories option, Paul Eggert, 2003/05/30
- Re: Grep --directories option, Jeff Bailey, 2003/05/30
- Re: Grep --directories option,
Patrick Strasser <=
- Re: Grep --directories option, Marcus Brinkmann, 2003/05/31
- Re: Grep --directories option, Paul Eggert, 2003/05/30
- Re: Grep --directories option, Alfred M. Szmidt, 2003/05/31
- Re: Grep --directories option, Marcus Brinkmann, 2003/05/31
- Re: Grep --directories option, James Morrison, 2003/05/30
- Re: Grep --directories option, Paul Jarc, 2003/05/30
Re: Grep --directories option, Stepan Kasal, 2003/05/30