drblove27 has asked for the wisdom of the Perl Monks concerning the following question:
So almost an example cut and paste from the CPAN page, now my original thought is that $tar is then a long string that I can do what I want. But when I printed it out I got the following:#!/usr/bin/perl -w use strict; use Archive::Tar; my $tar = Archive::Tar->new; $tar->read('file.tar.gz'); $tar->extract();
Ok... So it is a hash, but I don't know what the keys are, so doing a little digging in Perl Cookbook I get a snippet of code to tell me what the keys are and find out that $tar is not a hash... stumped... In theory all I would like to do it dump the contents of the tar.gz file into a string then slice and dice, but I can't seem to get to the contents. Can any one point me in the right direction? I would really appreciate it. CheersArchive::Tar=HASH(0x2dd2a4)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Archive::Tar basic question
by graff (Chancellor) on Aug 04, 2009 at 03:12 UTC | |
by drblove27 (Sexton) on Aug 04, 2009 at 03:18 UTC | |
|
Re: Archive::Tar basic question
by halfcountplus (Hermit) on Aug 04, 2009 at 01:29 UTC | |
by drblove27 (Sexton) on Aug 04, 2009 at 02:24 UTC | |
by Anonymous Monk on Aug 04, 2009 at 03:11 UTC | |
by drblove27 (Sexton) on Aug 04, 2009 at 03:14 UTC |