I have to untar a tar file that has around 14,000 files. I viewed the contents using tar -tf and would like to extract them into subdirectories based on the filenames, for example I wish to extract filenames starting with rem1 into one subdirectory and rem2 into another.
What is the best way to do this in Perl?
Thanks
Anu