Warning: file_get_contents(/data/phpspider/zhask/data//catemap/4/macos/8.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181

Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/image-processing/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Bash 使用自定义域名从终端(Mac OS x)发送邮件_Bash_Macos_Email_Mutt - Fatal编程技术网

Bash 使用自定义域名从终端(Mac OS x)发送邮件

Bash 使用自定义域名从终端(Mac OS x)发送邮件,bash,macos,email,mutt,Bash,Macos,Email,Mutt,我想用自定义发件人域名发送邮件 cat email_format.html | mutt -e "set content_type=text/html;" -s "Test mail - HTML" arun*****@gmail.com 如果从终端使用上述命令,邮件已发送,但发件人地址如下所示:arun。srinivasan@localdomain.localdomain 我想让发件人的邮件id像这样From:arun。srinivasan@mycompany.com?@KamilCuk我已

我想用自定义发件人域名发送邮件

cat email_format.html | mutt -e "set content_type=text/html;" -s "Test mail - HTML" arun*****@gmail.com
如果从终端使用上述命令,邮件已发送,但发件人地址如下所示:arun。srinivasan@localdomain.localdomain


我想让发件人的邮件id像这样
From:arun。srinivasan@mycompany.com

?@KamilCuk我已经试过了。当我使用
mutt-e“set content\u type=text/html;”
而不使用任何发件人地址时,它可以完美地工作。如果我像这样使用from地址
mutt-e“set content\u type=text/html;my\u hdr from:arun。srinivasan@mycompany.com“
命令执行时没有错误,但收件箱或垃圾邮件文件夹中似乎也没有收到邮件。这不是多个-e参数吗
mutt-e'set content\u type=text/html'-e'my\u hdr From:sender@company.com“
。邮件变量是否有效?否@KamilCuk。它不起作用:(