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

Re: using locate properly



On Tue, 2002-10-08 at 15:15, Robert Wilhelm Land wrote:
> This could be more a question of bash fundamentals:
> 
> By trying to find Muttrc on my HDD I used the locate
> program.
> 
> This was the command I ueed:
> 
> rland@MINI:~$ locate [Mm]uttrc
> ... no reaction.

<snip>

> .....so I tried:
> 
> rland@MINI:~$ locate '[Mm]uttrc'
> rland@MINI:~$ locate "[Mm]uttrc"
> ...nothing.
> 
> But:
> rland@MINI:~$ locate &pi0;[Mm]uttrc'
>  >
> ....put the bash into this ">" - mode and could
> only be reset by ctrl+C.
> 
> What has happened here?
> I would be awfully grateful if someone would help.

If you specify a shell pattern to search for, the file needs to match
exactly to this pattern (including the directory part). 

$ locate '*/[Mm]uttrc'

Sorry, I can't read the special characters you've used throughout your
last paragraphs - so, I can't help you there. Probably "&pi0;" is a
quoting character and you forget to end the string with the same
character.

-- 
Claudio Bley                                 ASCII ribbon campaign (")
Debian GNU/Linux advocate                     - against HTML email  X 
http://www.cs.uni-magdeburg.de/~bley/                     & vCards / \



Reply to: