[Chicago-talk] help with system call
Richard Reina
richard at rushlogistics.com
Mon Dec 27 08:13:00 PST 2010
I am trying to incorporate ripmime into my perl script to extract (one message at a time) the attachments from email messages. The problem I am having is that, though I have searched extensively, I cannot find a ripmime option that allows me to rename the file to a name provided by the script ($id_number).
So I figure I need to get perl to rename the file (attachment) for me but I don't know it's current name? The ripmime man pages say there are not any environment variables --if that matters?.
What I need is for the extracted attachment to take on the name of $id_number.
what I have so far:
sub strip_attachments {
my ($id_number) = @_;
#strip the attachment off the lone email waiting in mail_with_atchmnt
system("ripmime -i /home/richard/mail/.inboxes/mail_with_atchmnt -v -d /home/richard/attachments/");
} # end of sub
Any help would be greatly appreciated.
Thanks,
Richard
--
Richard Reina
Rush Logistics, Inc.
Watch our 3 minute movie:
http://www.rushlogistics.com/movie
More information about the Chicago-talk
mailing list