开发者

Unix mail utility - 'You must specify direct recipients with -s, -c, or -b'

开发者 https://www.devze.com 2023-01-25 18:07 出处:网络
Wikipedia says that this should work: echo \"Some message\" | mail -s \"meeting today\" somebody@example.com

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)

0

精彩评论

暂无评论...
验证码 换一张
取 消