No description, website, or topics provided.
Switch branches/tags
Nothing to show
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Failed to load latest commit information.
gymail
.gitignore
PKGBUILD
README.md
gymail.conf
gymail.install
setup.py

README.md

gymail

gymail is a simple python mail notification script with three eligible event types (error, warning and info), for each a different visual style is applied in the html body. Use it in cli or as python module.

Requirements:

pip3 install helputils

Configuration:

Add your mail provider data to /etc/gymail.conf

CLI usage

usage: gymail.py [-h] -e {error,warning,info} -s SUBJECT -m MSG

Simple sendmail script.

optional arguments:
  -h, --help            show this help message and exit
  -e {error,warning,info}, --event {error,warning,info}
                        Formats html style for email accordingly.
  -s SUBJECT, --subject SUBJECT
                        Subject of email.
  -m MSG, --msg MSG     Email message goes here.

CLI example:

gymail.py -e info -s Backup -m "Backup was successful"

Module usage:

import os
from gymail.core import send_mail
send_mail(event="info", message="example", subject="example")
send_mail(event="info", subject=os.path.basename(__file__), message="Your message here")