How to read mail attachement

I want to read attachements sent to unix mail id and save the attachement in folder.

I may receive the mails from different mail clients(outlook, lotus ..etc).

Attachements are in CSV(comma saperate) format.

Let me know the shell script code for this.

Regards,
Venkat

I remember I used the tool "munpack" to separate attachments from the mail text, worked fine iirc. Maybe there is an easier way though.