Simple tool for sending email with sendmail, postfix or ssmtpd.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Holger Frey f761b74849 fixed path to sendmail 6 years ago
.gitignore first writedown of code 6 years ago
LICENSE Initial commit 6 years ago
Pipfile first writedown of code 6 years ago
README.md first writedown of code 6 years ago
pysema.py fixed path to sendmail 6 years ago

README.md

pysendmail

Simple tool for sending email with sendmail, postfix or ssmtpd.

Example: {{{ import pysema

pysema.send(
    ['alice@example.com', 'bob@example.com'],
    'really good subject line',
    'Message body goes here'
    )

}}}

If you need to send some complex message, use email.message from the Python standard library to construct the message (including header fields) and pass it to the send_message function:

{{{ import pysema from email.message import EmailMessage

msg = EmailMessage()
# compose message

pysema.send_message(msg)

}}}

if something goes whoopsie a pysema.SendMailException is raised.