develooper Front page | perl.beginners | Postings from March 2002

Re: mail

Prahlad Vaidyanathan
March 2, 2002 03:28
Re: mail
Message ID:

On Fri, 11 Jan 2002 Pieter Blaauw spewed into the ether:
> Hi guys
> How would I do the following. Platform is a Red Hat 7.2 Linux box with
> Pine 4.44 as my mail client. Now pine stores all your mail in the usual
> /var/spool/mail/<username>
> Can I use perl to extract all the mail from 2001 into another big file
> that I could use as a backup of last years mail. I have over a thousand
> messages in it so doing it manually is pretty impossible. I'd like to keep
> the messages for this month so far in the maildir otherwise I could have
> easily just moved the /var/spool/mail/<username> somewhere as a backup and
> problem solved.

Not a perl solution, but I'm sure Pine has some way of tagging/moving
messages according to a specific pattern. Under Mutt, it's quite easy,
and IMHO, you'll be better served by your MUA rather than perl.


ps. Another thing, it may not be such a good idea to leave your mail in
the spool directory. It makes more sense to save it in your home
directory ( ~/Email, say). Simply because you always have control over
your own home directory.

Prahlad Vaidyanathan <>

"Don't talk to me about disclaimers!  I invented disclaimers!" Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About