将我的学院邮件转发到 Gmail?

dex*_*dev 5 email procmail

我想将来自我学院邮件的电子邮件转发到我的 gmail,同时将原件也保留在学院帐户中。我尝试编辑我的/.procmail文件,如下所示:

# Forward everything to me at gmail
:0:
! myusername@gmail.com
Run Code Online (Sandbox Code Playgroud)

这工作正常,除了原始邮件只是退回到 gmail 帐户,而不是存储在学院邮件帐户中。为此该怎么办?

小智 10

使用:0c用于转发邮件的副本

:0c
! myusername@gmail.com
Run Code Online (Sandbox Code Playgroud)

c 标志文档:

c    Generate  a  carbon  copy  of this mail.  This only makes sense on delivering recipes.  The only
        non-delivering recipe this flag has an effect on is on a nesting block, in order to  generate  a
        carbon  copy  this  will  clone  the running procmail process (lockfiles will not be inherited),
        whereby the clone will proceed as usual and the parent will jump across the block.
Run Code Online (Sandbox Code Playgroud)