我需要使用脚本定期发送生成的 CSV 文件。我正在使用UUENCODE
和mailx
。
但我需要知道有什么方法/方法可以知道电子邮件发送成功吗?任何形式的确认或反馈或其他东西???
它很可能会报告任何错误。此外,该文件是机密的,不会偏离某些外部路径。
编辑:用于邮寄的代码。
subject="Something happened"
to="na734@company.com"
body="Attachment Test"
attachment=/home/iv315/timelog_file_150111.csv
(cat test_msg.txt; uuencode $attachment somefile.csv) | mailx -s "$subject" "$to"
Run Code Online (Sandbox Code Playgroud) grep
a
在搜索字母时表现不同。当字母a
包含在搜索条件中时,它不会搜索任何其他字母。但其他角色的情况就不一样了。为什么?!
对于命令 : grep [aeiou] file1
or grep [eioau] file1
or grep [a,e,i,o,u] file1
,它显示以下输出:
Name : file1
a
Run Code Online (Sandbox Code Playgroud)
注1:字母“a”在输出中被突出显示为搜索字符(附截图)。
对于 command : grep [eiou] file1
or grep [e,i,o,u] file1
,它显示以下输出:
this is test file.
Name : file1
Run Code Online (Sandbox Code Playgroud)
注2:字母“e”和“i”在输出中被突出显示为搜索字符(附截图)。
文件 1是:
this is test file.
Name : file1
a
Run Code Online (Sandbox Code Playgroud)