[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: problem with egrep and fgrep

From: Bob Proulx
Subject: Re: problem with egrep and fgrep
Date: Sun, 12 Sep 2004 10:56:32 -0600
User-agent: Mutt/1.3.28i

Stepan Kasal wrote:
> Warren L Dodge wrote:
> > I think the egrep and fgrep were links to grep rather then a small script.
> Yes, that's the traditional UNIX approach.
> But I think tehy were different binaries for quite a long time, then links
> for a short time.
> The current approach is required of GNU coding standards, though it generates
> some protests.

Could you elaborate on why this is required by the GNU coding
standards?  I am aware of section 4.4 which says:

  Please don't make the behavior of a utility depend on the name used to
  invoke it. It is useful sometimes to make a link to a utility with a
  different name, and that should not change what it does.

  Instead, use a run time option or a compilation switch or both to
  select among the alternate behaviors.

Given that, and not knowing anything else, wouldn't it be best to
provide 'egrep' and 'fgrep' which are individual binaries with the -E
and -F options enabled as appropriate?  This would then be a similar
case to the 'ls' and 'dir' example.  I understand that another group
of people will complain that disk space is wasted by what is
essentially another copy of the same program.  But I am sure there are
other reasons of which I am not aware that went into the current


reply via email to

[Prev in Thread] Current Thread [Next in Thread]