Re: [gentoo-user] Search filesystem with a wildcard

2011-03-01 Thread Grant
>> I'm having trouble with this again.  I get: >> >> # ls -l /var/cache/revdep-rebuild >> total 424 >> -rwx-- 1 root portage    699 Feb 28 16:52 0_env.rr >> -rwx-- 1 root portage 323445 Feb 28 16:38 1_files.rr >> -rwx-- 1 root portage  34387 Feb 28 16:38 2_ldpath.rr >> -rwx-- 1 root

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-28 Thread Alex Schuster
Grant writes: > I'm having trouble with this again. I get: > > # ls -l /var/cache/revdep-rebuild > total 424 > -rwx-- 1 root portage699 Feb 28 16:52 0_env.rr > -rwx-- 1 root portage 323445 Feb 28 16:38 1_files.rr > -rwx-- 1 root portage 34387 Feb 28 16:38 2_ldpath.rr > -rwx-

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-28 Thread Grant
>>> I used to use slocate like this to search the filesystem for a file: >>> >>> foo*.txt >>> >>> but mlocate doesn't seem to accept wildcards.  I tried to figure out >>> how to do it with find but failed.  Can anyone point me in the right >>> direction? >>> >>> - Grant >>> >>> >> >> Try locate "*/

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-27 Thread Grant
>> I can't get find to work.  This works: >> >> locate *foo*.txt >> >> but none of these work: >> >> find /my/folder -name foo*.txt >> find /my/folder -name *foo*.txt >> find /my/folder -type f -name '*foo*.txt' > > $ mkdir -p  /my/folder > mkdir: cannot create directory `/my': Permission denied >

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-27 Thread Willie Wong
On Sun, Feb 27, 2011 at 06:52:36AM +, Stroller wrote: > AIUI using `find /my/folder -name foo*.txt` (i.e. unquoted) the shell will > pass the * to find if it can't expand it itself. Not necessarily true. On bash if you set the 'nullglob' option, if the shell can't find the file the word wil

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread Stroller
On 27/2/2011, at 6:30am, Alan McKinnon wrote: > On Sunday 27 February 2011 03:46:48 Stroller wrote: >> On 26/2/2011, at 5:33pm, Grant wrote: >>> >>> find /my/folder -type f -name '*foo*.txt' >> > > He didn't quote the search string and neither did the grandparent. Find will > do what he's aski

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread Stroller
On 26/2/2011, at 5:33pm, Grant wrote: > I can't get find to work. This works: > > locate *foo*.txt > > but none of these work: > > find /my/folder -name foo*.txt > find /my/folder -name *foo*.txt > find /my/folder -type f -name '*foo*.txt' $ mkdir -p /my/folder mkdir: cannot create directory

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread Roman Zilka
> >> I used to use slocate like this to search the filesystem for a file: > >> > >> foo*.txt > >> > >> but mlocate doesn't seem to accept wildcards.  I tried to figure out > >> how to do it with find but failed.  Can anyone point me in the right > >> direction? > >> > >> - Grant > > > > How about t

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread luis jure
on 2011-02-26 at 09:33 Grant wrote: >I can't get find to work. This works: > >locate *foo*.txt > >but none of these work: > >find /my/folder -name foo*.txt >find /my/folder -name *foo*.txt >find /my/folder -type f -name '*foo*.txt' > >What am I doing wrong? I do need the find to be recursive in

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread Grant
>> I used to use slocate like this to search the filesystem for a file: >> >> foo*.txt >> >> but mlocate doesn't seem to accept wildcards.  I tried to figure out >> how to do it with find but failed.  Can anyone point me in the right >> direction? >> >> - Grant > > How about this? > > find -name fo

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread Grant
>> I used to use slocate like this to search the filesystem for a file: >> >> foo*.txt >> >> but mlocate doesn't seem to accept wildcards.  I tried to figure out >> how to do it with find but failed.  Can anyone point me in the right >> direction? >> >> - Grant >> >> > > Try locate "*/foo*.txt". ml

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-26 Thread Roman Zilka
Amankwah (Sat, 26 Feb 2011 11:19:22 +0800): > On Fri, Feb 25, 2011 at 06:26:51PM -0800, Grant wrote: > > I used to use slocate like this to search the filesystem for a file: > > > > foo*.txt > > > > but mlocate doesn't seem to accept wildcards. I tried to figure out > > how to do it with find bu

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-25 Thread Mike Gilbert
On Fri, Feb 25, 2011 at 10:19 PM, Amankwah wrote: > How about this? > > find -name foo*.txt ? Why would you scan the entire file system when you have an speedy index?

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-25 Thread Mike Gilbert
On Fri, Feb 25, 2011 at 9:26 PM, Grant wrote: > I used to use slocate like this to search the filesystem for a file: > > foo*.txt > > but mlocate doesn't seem to accept wildcards.  I tried to figure out > how to do it with find but failed.  Can anyone point me in the right > direction? > > - Grant

Re: [gentoo-user] Search filesystem with a wildcard

2011-02-25 Thread Amankwah
On Fri, Feb 25, 2011 at 06:26:51PM -0800, Grant wrote: > I used to use slocate like this to search the filesystem for a file: > > foo*.txt > > but mlocate doesn't seem to accept wildcards. I tried to figure out > how to do it with find but failed. Can anyone point me in the right > direction? >

[gentoo-user] Search filesystem with a wildcard

2011-02-25 Thread Grant
I used to use slocate like this to search the filesystem for a file: foo*.txt but mlocate doesn't seem to accept wildcards. I tried to figure out how to do it with find but failed. Can anyone point me in the right direction? - Grant