code cleanup

Bruce Evans bde at zeta.org.au
Sat May 1 20:28:44 PDT 2004


On Sat, 1 May 2004, David O'Brien wrote:

> On Fri, Apr 30, 2004 at 11:28:09PM +1000, Bruce Evans wrote:
> > so I don't have any object files under /sys to slow down the search,
> > except grep -r would follow this symlink too.
> >
> > Perhaps it is a bug for grep -r to follow symlinks by default, especially
> > since there is no way to change the default and whether symlinks are
> > followed is not mentioned in the man page.
>
> '-R' is an undocumented alias for '-r'.  Perhaps we could turn '-R' into
> '-r' but not following symlinks.

I think all utilities that recurse (and some that don't) should support
the POSIX -R [-H | -L | -P] flags like cp, and strongly deprecate -r
like cp.  This gives a superset of the above behaviour.

Bruce


More information about the freebsd-current mailing list