Acme::Archive::Mbox - Mbox as an archive format.


Version 0.01


Uses Mbox as an archive format, like tar or zip but silly. Creates an mbox with one message per file or directory. File contents are stored as an attachment, metadata goes in mail headers.

    use Acme::Archive::Mbox;

    my $archive = Acme::Archive::Mbox->new();
    $archive->add_data('file/name', $contents);




new ()

Create an Acme::Archive::Mbox object.

add_data ($name, $contents, %attr)

Add a file given a filename and contents. (File need not exist on disk)

add_file ($name, [$archive_name])

Add a file given a filename. File will be read from disk, leading slashes will be stripped. Will accept an optional alternative filename to be used in the archive.

get_files ()

Returns a list of AAM::File objects.

write (filename)

Write archive to a file

read (filename)

Read archive from a file.


Ian Kilgore, <iank at>


Undefined behavior in spades. Anyone using this probably deserves it.
Fails to overwrite or truncate when creating archives
As Acme::Archive::Mbox does not store directories, directory mode and ownership will not be preserved.


You can find documentation for this module with the perldoc command.

    perldoc Acme::Archive::Mbox

You can also look for information at:



Copyright 2008 Ian Kilgore, all rights reserved.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.