我需要做的是通过我首选的SMTP服务器发送电子邮件,但将这些邮件保存到IMAP服务器上我的GMAIL帐户发送文件夹中。我真的很难做到这一点。
我可以发送没有问题,但我无法保存imap[Gmail]发送的邮件。雷鸟可以完美地做到这一点,所以这只是一个配置问题。
我尝试了很多事情,比如:
set record = imaps://imap.gmail.com/INBOX/INVIATA
set record = "+[Gmail]/Sent Mail"
set record = "+[Gmail]/Posta inviata"
它就是不起作用。
这是我的. muttrc文件:
# About Me
set from = "my.name@SMTPAccount.it"
set realname = "John Doe"
set imap_user = "john.doe@gmail.com"
# My mailboxes
set imap_pass = $GMAIL_PASS
set folder = imaps://imap.gmail.com/
set spoolfile = imaps://imap.gmail.com/INBOX
# SMTP user auth
# # fill in the right user and pass based on your setup
# # protocols: smtp for TLS (25/587), smtps for SSL (465)
set smtp_url = "smtps://john.doe@smtpAccount.it@mail.smtpAccount.it:465/"
set smtp_pass = $SMTP_PASS
# Where to save copies of outgoing mail
#here what I have tried so far:
#set record = imaps://imap.gmail.com/SENT
#set record = "imaps://imap.gmail.com/[Gmail]/inviata"
#set record = imaps://imap.gmail.com/INBOX/INVIATA
#set record = "+[Gmail]/Sent Mail"
#set record = "+[Gmail]/Posta inviata"
set record = +[Gmail]/Sent Mail
# Where to put the stuff
set header_cache = "~/.mutt/cache/headers"
set message_cachedir = "~/.mutt/cache/bodies"
set certificate_file = "~/.mutt/certificates"
看起来你想要使用谷歌的SMTP服务器。如果是这种情况,请将记录设置为空字符串,因为它会自动保存已发送的邮件。
set smtp_url = 'smtps://yourusername@smtp.gmail.com'
set smtp_pass = 'yourpassword'
set record=""