A message for Linux.com registered users: We are in the process of making changes to the Linux forums. Starting Monday, 8/13/18 at 6:00 PM PT, you will be unable to access the forums. They will re-launch as soon as possible on Wednesday, 8/15/18 with new features and improved functionality. Thank you for your patience and stay tuned for the new improved forums.

July 16, 2009

Automatic email printing


Ive been looking for a way to automatically print emails that i get via fetchmail that all have a certain string in the subject.

So far what i have patched together is fetchmail retrieves the emails via pop3. The email server deletes them once downloaded. and they are sent to a mail spool file in /var/mail/ via sendmail.

What i think needs to be done is between fetchmail and sendmail procmail should be used to sort the emails. Then i would guess that procmail should move the correct emails to a directory that then gets printed.

The reason for this is I have a few companies that send emails to my address and i need/want hard copies of the mail. Right now im sorting them manually every few days and printing them in batch.

It would be great if someone could tell me how to get procmail intergrated because i have no idea how to. I have looked at ~10 different pages that show to to do this in 10 different ways.

Click Here!