Unix mail utility - 'You must specify direct recipients with -s, -c, or -b'
Wikipedia says that this should work:
echo "Some message" | mail -s "meeting today" somebody@example.com
But I do not get any mails, instead an error message:
$ echo "world" | mail -s "hello, " -c lazer@gmail.com
You must specify direct recipients with -s, -c, or -b.
$
What is the 开发者_JS百科correct way to use mail
?
You are trying to send mail without specifying the To:
, just who you are CC-ing it to.
Do something like:
echo "world" | mail -s "hello, " me@myself.com -c lazer@gmail.com
To send it to yourself, but CC it to the person you wanted to CC it to (or just send it to them without the -c
flag)
精彩评论