-
-
Notifications
You must be signed in to change notification settings - Fork 109
Open
Description
Hi, I am trying to pick files and directories from multiple directories for further processing in my programme logic.
I am able to pick majority of the files and directories. However, with -f and all other remaining file operators, I am unable to pick following type of files from the cache folder.
1: //4-http∺∯∯wscont1.apps.microsoft.com∯winstore∯1.8x∯2d60181a-b6d7-499a-9414-f07b0f932419∯AppTile.1.396657.404061.png
2: //4-https∺∯∯wscont.apps.microsoft.com∯winstore∯6.3.0.1∯100∯GB∯en-us∯MS∯467∯features1de1406b-b4ec-4d86-9066-68bf9c5d67f2.json
3: etc.
Can someone advise, which code to use to pick this type of files being present in ‘a directory’?
I am using following code:-
for (@files) { $element = $_; if (-d $_) { push @directories, process_files ($_); ++$dir_counter; # print NOW “Dir is – $_\n”;
} elsif (-f $_) { ++$file_counter; # print NOW “File is – $_\n”; next; }
elsif ($_ =~ /\.dat$/i || $_ =~ /\.png$/i) { ++$file_counter; print NOW “This is not ordinary file – $_\n”; next;
} else { print NOW “I am in else statement: process_files($_)\n”; }
# else loop end
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels