Archive::Merged - virtually merge two archives
my $merged = Archive::Merged->new( Archive::Tar->new( 'default_theme.tar' ), Archive::SevenZip->archiveTarApi( archivename => 'theme.zip' ), Archive::Dir->new( 'customized/' ), );
Archive::Merged->new
my $merged = Archive::Merged->new( Archive::Tar->new( 'default_theme.tar' ), Archive::Dir->new( 'customized/' ), );
Creates a new archive as the merged view of one or more archives or directories.
->directory
->archives
my @archives = $merged->archives;
Accessor for the archives that represent this archive.
->contains_file
if( $merged->contains_file( $file ) ) { print "Yay!" } else { print "File '$file' not found"; };
Returns the underlying archive that contains the file. Returns undef if the file is not found.
->get_content( $file, %options )
my $content = $merged->get_content( $file, binmode => ':raw' )
Returns the content of the file, potentially with the encoding.
->list_files( )
my @contents = $merged->list_files;
Lists the contained files of the archive. Files that are shadowed are only listed once.
->extract_file( )
$merged->extract_file( $name => $target );
Extracts the file to the target name.
The public repository of this module is http://github.com/Corion/archive-merged.
The public support forum of this module is https://perlmonks.org/.
Please report bugs in this module via the RT CPAN bug queue at https://rt.cpan.org/Public/Dist/Display.html?Name=Archive-Merged or via mail to archive-merged-Bugs@rt.cpan.org.
Max Maischein corion@cpan.org
corion@cpan.org
Copyright 2015-2016 by Max Maischein corion@cpan.org.
This module is released under the same terms as Perl itself.
Archive::Tar
Archive::SevenZip::API::ArchiveTar
To install Archive::Merged, copy and paste the appropriate command in to your terminal.
cpanm
cpanm Archive::Merged
CPAN shell
perl -MCPAN -e shell install Archive::Merged
For more information on module installation, please visit the detailed CPAN module installation guide.