use strict; use warnings; use MIME::Parser; ## my alias line: ## menu: \menu, "|/usr/perl/mime.parser.p" ## '\menu' keeps a copy in the inbox for account menu my $parser = new MIME::Parser; ## The secret here is that the directory must pre-exist ## and must be writable by the daemon that runs the ## parsing script. In my case user=daemon group=other ## I determined the correct values by initially making ## /tmp/mimemail using permissions 777. $parser->output_dir("/tmp/mimemail"); my $entity = $parser->read(\*STDIN) or die "\n\nCouldn't parse MIME stream\n\n";