in reply to Perl List files in directory
Hi,
I tried using :
@files = glob("/opt/tmp/*");
i don't get any output. I checked the folder permissions and i have : drwxrwxwx
I also tried:
opendir(DIR, "/opt/tmp/") or die "Cannot open dir"; @files = grep {"/opt/tmp/*.xml"} readdir DIR;
I get an error : "Cannot open dir". However, like i mentioned before the folder as all permissions
I tried using Tiny, but i got an error saying: "can't locate Path/Tiny.pm in @INC
Im going to try and use find next
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Perl List files in directory
by Corion (Patriarch) on Apr 22, 2014 at 14:23 UTC | |
by Anonymous Monk on Apr 22, 2014 at 14:31 UTC | |
by Corion (Patriarch) on Apr 22, 2014 at 14:31 UTC |