Re: Finding files by Extention in a CLI

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

 



On Fri, Feb 11, 2005 at 12:13:23PM -0600, H. Streit wrote:
> Okay, so I've just copied over a bunch of files and I want to find all 
> .com/.COM/.Com files...
> I thought "find . -print|grep -i ".com" would work, tried a few 
> variants, but I know I'm doing something wrong...any takers?

That will work, except it matches anything which contains the string "com"
preceded by any character. It's also inefficient since the find command
itself can do the filtering. Try this:

  find . -iname '*.com'


-- 
Matthew Miller            mattdm@xxxxxxxxxx        <http://www.mattdm.org/>
-->  Fedora Users & Developers Conference, hosted by Boston University  <--
February 18th, 2005                       <http://fedoraproject.org/fudcon/>  


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux