[plug] hidden files
Richard Meyer
meyerri at au1.ibm.com
Wed Aug 20 10:59:18 WST 2003
----- Forwarded by Richard Meyer/Australia/Contr/IBM on 20/08/2003 10:51 AM
-----
Ben New
<ben at leftclick.co To: plug at plug.linux.org.au
m.au> cc:
Subject: Re: [plug] hidden files
20/08/2003 10:42
AM
Please respond to
plug
>Richard Meyer wrote:
>>find / -name .* -print
>>
>>This will scan the whole directory structure for everything whose name
>>starts with a ".", and print the result.
>>
>>
>Sorry Richard, that won't work for 2 reasons-
>1. the shell will expand the * before it executes find, making the
>params for find incorrect, and
>2. even if you quoted or escaped the ".*", the find will also find the
>"." and ".." entries of each directory, which happen to start with a
>".", thereby finding every directory in the system.
Hmm, I've used expressions of the form "-name fred*" before, but maybe
there is a problem with ".*". I don't have a Linux box around to check. As
for no 2 the user can easily ignore . and .. - quick and dirty is the way
to go - a quick run through sort and the lines could be deleted easily ;)
>You might have to play around with the -regex option or something. (This
>is assuming that you meant "files with names that start with a dot" when
>you say "hidden files")
Well I was assuming that's what Jon meant, since it is a Linux list, and it
appears I get 10/10 for ESP, even if I left out the quotes, so after
subtracting 5 points for that, I still get 50%. :)
Thanks for the correction
RichardM
>Regards,
>Ben
More information about the plug
mailing list