This is the mail archive of the cygwin@cygwin.com mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: ls -R doesn't work; V1.3.12 on Win2000


On Sat, Jul 06, 2002 at 08:59:17AM +0100, Jim George wrote:
>it doesn't work in 1.3.11 either.
>
>You can always pipe it to grep (ls -laR | grep '.DOC' for example).

It "doesn't work" because it doesn't actually work that way.  It doesn't
work that way on any linux/unix system.  The -R option doesn't mean
"match the command line arguments throughout all directories".  It means
"If, when listing files, you hit a directory, recurse into it."

In other words, 'ls' is working as designed.  This is a common
misconception of the -R option.

cgf

>----- Original Message ----- 
>From: "Hari Turlapati" <hturlapati@yahoo.co.in>
>To: <cygwin@cygwin.com>
>Sent: Friday, July 05, 2002 8:14 PM
>Subject: ls -R doesn't work; V1.3.12 on Win2000
>
>
>> The command "ls -laR *.doc" (Recursive listing of *.doc or *.pdf or
>> *.rtf, in general files with specific extension) under a subdirectory to
>> /cygdrive/c/ doesn't work. Even "ls -laR *.*" doesn't work.
>> 
>> But "ls -laR *" lists all the files under the subdirectories.
>> 
>> I am using CygWin Release 1.3.12-1 on Win2000 OS. The command "uname -a"
>> on my machine prints out the following:
>> 
>> CYGWIN_NT-5.0 HariPC 1.3.12(0.54/3/2) 2002-07-03 16:42 i686 unknown
>> 
>> Thanks
>> 
>> Hari
>> 
>> 
>> 
>> _________________________________________________________
>> Do You Yahoo!?
>> Get your free @yahoo.com address at http://mail.yahoo.com
>> 
>> 
>> --
>> Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>> Bug reporting:         http://cygwin.com/bugs.html
>> Documentation:         http://cygwin.com/docs.html
>> FAQ:                   http://cygwin.com/faq/
>> 
>
>
>--
>Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
>Bug reporting:         http://cygwin.com/bugs.html
>Documentation:         http://cygwin.com/docs.html
>FAQ:                   http://cygwin.com/faq/

--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]