#!/bin/sh

# Make a copy of this and customize the variables

MAILFROM=cron@rpg.hamsterrepublic.com
MAILTO=cron@rpg.hamsterrepublic.com

SMTP="smtps://smtp.dreamhost.com:465"
USERNAME="cron@rpg.hamsterrepublic.com"
PASSWD="***redacted***"

# The $1 argument should be the filename of an e-mail message body to send.
# To, From, And Subject headers should be at the top. The other headers
# will be generated by curl or the smtp server

curl $SMTP -s -S \
  --mail-from $MAILFROM \
  --mail-rcpt $MAILTO \
  --ssl --ssl-reqd \
  -u "$USERNAME":"$PASSWD" \
  --upload-file "$1"
