I need my script to send an email from terminal. Based on what I\'ve seen here and many other places online, I formatted it like this:
Please try to remove the preceeding spaces before EOF:-
EOF
/var/mail -s "$SUBJECT" "$EMAIL" <<-EOF
Using <tab> instead of <spaces> for ident AND using <<-EOF works fine.
<tab>
<spaces>
The "-" removes the <tabs>, not <spaces>, but at least this works.
"-"
<tabs>