【问题标题】:mailx how to pipe the messages repeatedly through a commandmailx如何通过命令重复管道消息
【发布时间】:2018-10-24 09:51:51
【问题描述】:

操作系统 linux Ubuntu 16.04

使用mailx(或其他实用程序)我需要将邮箱内的消息一一重复地通过管道传递给命令。

一旦启动mailx,我会尝试迭代地执行命令:

pipe . munpack

上面的意思应该是“将当前消息传递给命令 munpack”

但它会回答:

Pipe to: "munpack"
munpack: reading from standard input
Did not find anything to unpack from standard input
"munpack" 18224 bytes

如果可行,我不知道如何迭代(而不是发送所有消息)。

【问题讨论】:

    标签: shell mailx


    【解决方案1】:

    管道命令只输出消息的第一个文本部分,而不是包括附件在内的所有消息。 所以 munpack 无法解压并给出上述误导性信息。 这样做的方法是使用 mailx 中的 write 命令保存附件,然后查看如何处理它们。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2014-07-23
      • 2011-01-17
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2013-06-17
      • 2015-02-05
      相关资源
      最近更新 更多