org-msg
org-msg copied to clipboard
Org-Msg ignores gnus-parameters, posting-styles
When using Org-Msg via (org-msg-mode), when writing a new message I see that gnus-parameters are ignored. They contain posting styles, e.g. the X-Message-SMTP-Method header used to specify the SMTP details which is missing. In addition my gnus-parameters also define gnus-message-archive-group/method used to get proper sent-messages archiving on IMAP using the Gcc header, which is also missing.
Expectation: Gnus logic regarding headers should stay intact.
Just to note, the setup function for Gnus posting styles is actually called; I am switching Org-Msg variables through the use of posting styles, although that is through the use of eval in the relevant posting style, and so it isn't ideal. I had to switch to programatically constructing the posting styles to help share the settings and I do have to slightly work around my signature being set for both Gnus and for Org-Msg.
It would be good to just use the posting styles as-is.
#1 could you provide a example failing case as I do not reproduce? #2 what would be the best approach to you ? Could you share how you are making use of gnus-parameter and why you think this is a better solution?
Hi, as I said, I'm using gnus-parameters as a multi-account system where - based on the group I'm in - the correct SMTP server is selected and sent messages are saved in the right place, whether it's local or in an IMAP sent "folder".
The way it works is simple; it's just adding 2 headers: X-Message-SMTP-Method and Gcc to the message.
Going through the code, I see the headers "from" "subject" "to" "cc" "date" being processed; can we just leave other fields as they are?
Here is an example; there are 2 accounts with different SMTP servers and different IMAP folders used for sent messages:
(setq gnus-parameters
'(("home"
(gnus-message-archive-method '(nnimap "Gmail"))
(gnus-message-archive-group "[Gmail]/Sent")
(gnus-posting-styles
'((".*"
(address "<[email protected]>")
("X-Message-SMTP-Method" "smtp smtp.gmail.com 587 [email protected]")))))
("work"
(gnus-message-archive-method '(nnimap "Work"))
(gnus-message-archive-group "[Gmail]/Work/Sent")
(gnus-posting-styles
'((".*"
(address "<[email protected]>")
("X-Message-SMTP-Method" "smtp smtp.gmail.com 587 [email protected]")))))))