Leo Butler <leo.but...@umanitoba.ca> writes:

>> --8<-----------------cut here----------------start--------------->8--
>> (defun my-configure-smtp-stream-type ()
>>   "Configure the SMTP stream type based on the current user email address."
>>   (cond ((equal user-mail-address "eg...@protonmail.ch")
>>          (setq smtpmail-stream-type 'ssl))
>>         ((equal user-mail-address "redac...@gmail.com")
>>          (setq smtpmail-stream-type 'starttls))))
>>
>> (add-hook 'message-send-hook #'my-configure-smtp-stream-type)
>> --8<-----------------cut here----------------end----------------->8--
>
> That function/hook is unnecessary. You can use
> `gnus-secondary-select-methods' or use the Server Buffer to configure
> the stream type.
>
> (info "(Gnus) Customizing the IMAP Connection")
> (info "(Gnus) Server Buffer")

The last thing I would have thought of is configuring SMTP settings
through IMAP connection customization. As I mentioned earlier, I
don't have any issues with reading emails from any of my accounts—the
problem was specifically with sending mail and selecting the correct
value for smtpmail-stream-type. Apologies if I misunderstood your
point, but I did read the info pages you referenced, and I didn't
find anything related to setting up SMTP there.

-- 
Serghei Iakovlev


  • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
    • ... Leo Butler
      • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
        • ... Xiyue Deng
          • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
        • ... Björn Bidar
        • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
          • ... Leo Butler
            • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
              • ... James Thomas
                • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
                • ... James Thomas
                • ... James Thomas
                • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
                • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)
                • ... Robert Pluim
                • ... Announcements and discussions for GNUS, the GNU Emacs Usenet newsreader (in English)

Reply via email to