Skip to content

Instantly share code, notes, and snippets.

@i40sys
Created March 1, 2022 06:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save i40sys/376b876a316a7cf3c9ce1beeb516102d to your computer and use it in GitHub Desktop.
Save i40sys/376b876a316a7cf3c9ce1beeb516102d to your computer and use it in GitHub Desktop.
#!/bin/bash
source config
function mailSend() {
TMP_FILE="/tmp/ups.email"
/bin/echo "To: $MAIL_NAME <$MAIL_RCPT>" > $TMP_FILE
/bin/echo "Subject: $1" >> $TMP_FILE
/bin/echo "" >> $TMP_FILE
/bin/echo "$2" >> $TMP_FILE
/usr/sbin/sendmail -v $MAIL_RCPT < $TMP_FILE
/bin/rm $TMP_FILE
}
#mailSend titol contingut
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment