Take the 2-minute tour ×
Unix & Linux Stack Exchange is a question and answer site for users of Linux, FreeBSD and other Un*x-like operating systems.. It's 100% free, no registration required.

I'm in the middle of writing a Python program which simply sends the same HTML message with an attachment to a large list of email addresses (BCC). Is there a utility I could use to do this rather than writing something from scratch? The actual email message doesn't vary at all, I simply need to send the same HTML and same attachment to all emails.

Does a Unix utility exist to provide this functionality?

share|improve this question

1 Answer 1

up vote 1 down vote accepted

You can use a command-line program such as or mutt. See http://www.mutt.org/.

Edit: have you looked at http://docs.python.org/library/email-examples.html?

share|improve this answer
    
Mutt is just a client, it doesn't have the ability to send mail (it uses sendmail or whatever) –  Michael Mrozek Mar 20 '12 at 0:37
    
@MichaelMrozek Well ... built-in SMTP was added to recent 1.5.x versions of mutt. –  jw013 Mar 20 '12 at 1:17
    
@jw013 Really? That's wildly un-Unix-y, but ok; nevermind then –  Michael Mrozek Mar 20 '12 at 1:40
    
@MichaelMrozek Indeed, the mutt wiki seems almost ashamed to admit it. Apparently it was a frequently requested feature though. –  jw013 Mar 20 '12 at 3:55
    
I wrote the program, wasn't too hard. I just have to fight my OCD to build "the best, most flexible Python email tool ever." –  Naftuli Tzvi Kay Mar 20 '12 at 15:30

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.