06 October 2006

Sending mail with attachments from the command line

echo "The body of the email" | mutt -s "The subject" -a file.txt somebody@somewhere.com

You can use multiple -a flags to and many attachments, mutt checks the file extension to determine the mime type