2014-02-24 31 views
1

我想自動生成原始回覆電子郵件的文本文件,例如,像下面的文本文件:如何使用Perl來生成原始回覆電子郵件

Subject: hello 
Mime-Version: 1.0 (Mac OS X Mail 6.6 \(1510\)) 
Content-Type: text/html; 
    charset=us-ascii 
X-Apple-Base-Url: x-msg://5/ 
X-Universally-Unique-Identifier: f3193934-f4df-4b36-95ab-36f3171570b8 
X-Apple-Mail-Remote-Attachments: YES 
From: Some Person <[email protected]> 
X-Apple-Windows-Friendly: 1 
Date: Mon, 24 Feb 2014 14:43:11 -0800 
X-Apple-Mail-Signature: SKIP_SIGNATURE 
Content-Transfer-Encoding: 7bit 
Message-Id: <[email protected]> 
X-Smtp-Server: mymachine 
X-Uniform-Type-Identifier: com.apple.mail-draft 
To: [email protected] 

<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; "></body></html> 

這是獲得從第一次回覆收到的電子郵件,然後在sent框中,我可以看到show original source

有什麼辦法自動生成這個電子郵件作爲文本文件,或打印出來的標準輸出?

+0

我不清楚你的意思。你能不能把它用引號括起來並把'print'放在它之前? – Borodin

+0

我的意思是說在文本中生成整個電子郵件,例如,如何獲得「X-Universally-Unique-Identifier」或「Message-Id」 –

回答

相關問題