in reply to reading mbox & deleting it

what I want to do is remove/delete the email I read..and so far I haven't found a way.
Do you have access to the mailbox via POP3? In that case, using Net::POP3 makes it easy.

Otherwise, if you insist on doing this with file operations: IMO that's risky, with multiple processes accessing the mailbox at the same time — new mail arriving, for example. Be very careful you get the file locking right.

Replies are listed 'Best First'.
Re^2: reading mbox & deleting it
by Krambambuli (Curate) on May 10, 2007 at 08:00 UTC
    Maybe Mail::Box is good for you. It has a lot of features, one of the handy ones being that you can easily save into an extra 'deleted' folder the messages that you are deleting (just in case... ;) ).