davidlevine: (southpark)
David D. Levine ([personal profile] davidlevine) wrote2006-01-14 10:32 am

OS X question

Because all knowledge is contained in LJ...

I would like to send mail from a shell script running on my Mac. How do I configure the "mail" command (or other command-line mail client) to send mail via my ISP using SMTP?

I'd rather not set up sendmail locally, nor do I need a fully-featured command-line mail client. I just want to send.

[identity profile] voidampersand.livejournal.com 2006-01-14 08:37 pm (UTC)(link)
I am not really an expert on this, but here are some ideas, and I'm sure someone will jump in and correct me if they're wrong. One is that you can SSH to your SMTP server and send the mail from there. Another would be to use a lightweight SMTP client. Perl has one that looks very easy to use. man Net::SMTP for documentation including sample code.