in reply to opendir in file find
Basically you want to ask the question "is this file a directory, and is this file not readable to me?" You can accomplish this with two file test operators...
Update: Slight correction, I think... I believe archon and I were both only half right. You'll want to use both the -r and -x file test operators, at least, based upon what your desire to "search" the directory, this is probably what you want."doh! can't read directory $file!\n" if (-d $file and not -r $file);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: opendir in file find
by BrowserUk (Patriarch) on Jul 25, 2003 at 17:14 UTC | |
by tye (Sage) on Jul 25, 2003 at 17:36 UTC | |
by BrowserUk (Patriarch) on Jul 25, 2003 at 18:11 UTC | |
by tye (Sage) on Jul 25, 2003 at 18:21 UTC | |
by BrowserUk (Patriarch) on Jul 25, 2003 at 19:14 UTC | |
by skyknight (Hermit) on Jul 25, 2003 at 17:28 UTC |