mailx-发送zip文件
我有一个名为:zip_final.zip的zip文件,
我必须将此文件作为附件附加并发送邮件。
另外,我必须显示邮件主体中zip文件中的所有file_names。
我有此代码:
export files_list=`unzip -Zl zip_final.zip`
mailx -a ${zip_final.zip} -s "Files list | Zip file" << EOM
Hi team, sent zip file.
Files inside it are : $files_list
Thank you.
EOM
但是如果我这样做,则不会发送邮件。就像邮件命令甚至没有被调用/触发。我什至没有收到任何错误消息。
有人可以建议如何使用mailx命令将邮政编码发送为附件,还可以在邮件正文中显示所有文件名?
I have a zip file named : zip_final.zip
I have to attach this file as a attachment and send the mail.
Also, I have to display all the file_names present inside the zip file in the mail body.
I have this code :
export files_list=`unzip -Zl zip_final.zip`
mailx -a ${zip_final.zip} -s "Files list | Zip file" << EOM
Hi team, sent zip file.
Files inside it are : $files_list
Thank you.
EOM
But the mail is not sent if I am doing this. Like the mail command is not even getting called/triggered. I am not even getting any error messages too.
Can someone suggest how to send that zipfile as an attachment using mailx command and also display all the file names inside the zipfile in the mail body?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论