[Linux-disciples] Clear out gnutella

Stephen R Laniel steve at laniels.org
Fri Jul 29 12:24:31 EDT 2005


On Fri, Jul 29, 2005 at 11:14:16AM -0500, Karl Sokol wrote:
> I am still trying to learn basic syntax.  When looking for ./fubar3, what does
> the second "." mean in the search ".*b.*3"?   I have noticed that if I fill
> space with a letter that it gets ignored as well.

Well, be careful: the meaning of '.*b.*3' is different in
the 'find' command depending on whether you're using the
'-iregex' argument instead of the '-iname' argument. The
iname argument uses shell wildcards, so

find ~ -iname '.*b.*3'

looks for any file under your home directory that begins
with a literal dot, then has any number of characters, then
has a literal 'b', then a literal dot, then any number of
characters, then a literal '3'. So the filename
'.foob.stuff3' matches, but the file 'foobstuff3' does not.

Now, if you use the iregex argument, find is now looking for
files that begin with any number of characters, followed by
a 'b', followed by any number of characters, followed by a
'3'. So now 'foobstuff3' matches, as does '.foob.stuff3'.

Does that make sense?

-- 
Stephen R. Laniel
steve at laniels.org
+(617) 308-5571
http://laniels.org/
PGP key: http://laniels.org/slaniel.key
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
Url : http://lists.bostoncoop.net/pipermail/linux-disciples/attachments/20050729/8bf59134/attachment.pgp


More information about the Linux-disciples mailing list