bug-gnu-utils
[Top][All Lists]
Advanced

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

Re: locate(1) man page hard to understand, please rewrite


From: Alfred M. Szmidt
Subject: Re: locate(1) man page hard to understand, please rewrite
Date: 08 Jul 2002 14:42:20 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

"Paul D. Smith" <address@hidden> writes:
> In fact, in shell pattern matching, unlike most regular expressions, the
> pattern must match the _entire_ filename.  So:
> 
>   $ locate /tmp
> 
> will match _only_ the exact path '/tmp'.  It will _NOT_ match anything
> containing '/tmp'; for the latter you need:
> 
>   $ locate '*/tmp*'

Sorry, but that is just wrong according to the output of locate:

$ locate /tmp
/home/ams/src/hurd/tmpfs
/home/ams/src/hurd/tmpfs/ChangeLog
/home/ams/src/hurd/tmpfs/CVS
/home/ams/src/hurd/tmpfs/CVS/Entries
/home/ams/src/hurd/tmpfs/CVS/Repository
/home/ams/src/hurd/tmpfs/CVS/Root

This looks like a bug to me.

After looking a bit closer the following would do what "locate /tmp"
is supposed to do (IHMO):

$ locate */tmp
/home/ams/share/doc/tmp

But it doesn't match /tmp for some odd reason.  `*' should match any
"zero or more characters"

Who is the current maintainer of GNU findutils?

Cheers,
-- 
Alfred M. Szmidt



reply via email to

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