Hi
I want to extract files from a .tar.gz archive one at a time and perform some computation on each file . Pls suggest a solution .. I tried the given below script but it is not sucessful.
use Archive::Tar; $input="libpst.tar.gz"; my $tar = Archive::Tar->new($input); my @files = $tar->list_files; foreach my $file (@files) { $tar->extract_file($file, "C:/extract/$input"); my $c++; print "$c"; }
The above script gives an error --> Could Not Open File C:/extract/libpst.tar.gz : Permission denied. I think i am not passing the correct extract_path as i want to extract the archive in a different directory. Please help?
In reply to Archive::Tar extract by gautamparimoo
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |