小编Sac*_*hin的帖子

有没有办法检查电子邮件发送成功确认?

我需要使用脚本定期发送生成的 CSV 文件。我正在使用UUENCODEmailx

但我需要知道有什么方法/方法可以知道电子邮件发送成功吗?任何形式的确认反馈或其他东西???

它很可能会报告任何错误。此外,该文件是机密的,不会偏离某些外部路径。

编辑:用于邮寄的代码。

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)

shell email mailx

3
推荐指数
1
解决办法
7549
查看次数

grep 行为异常

grepa在搜索字母时表现不同。当字母a包含在搜索条件中时,它不会搜索任何其他字母。但其他角色的情况就不一样了。为什么?!

对于命令 : grep [aeiou] file1or grep [eioau] file1or grep [a,e,i,o,u] file1,它显示以下输出:

Name : file1 
a
Run Code Online (Sandbox Code Playgroud)

注1:字母“a”在输出中被突出显示为搜索字符(附截图)。

对于 command : grep [eiou] file1or 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)

截屏

grep

2
推荐指数
1
解决办法
326
查看次数

标签 统计

email ×1

grep ×1

mailx ×1

shell ×1