Gnus development mailing list
 help / color / mirror / Atom feed
From: Richard Riley <rileyrg@gmail.com>
To: ding@gnus.org
Subject: Re: Can't send message through smtp with gmail
Date: Fri, 29 Jun 2012 01:47:11 +0200	[thread overview]
Message-ID: <ge1ukz9eyo.fsf@news.eternal-september.org> (raw)
In-Reply-To: <87395f88sy.fsf@gigabyte.lan>

mihkel <turakas@gmail.com> writes:

> Richard Riley <rileyrg@gmail.com> writes:
>>
>> my advice would be to use nognus and the built in multi smtp support.
>>
>> in your .authinfo:
>>
>> something like:
>>
>> machine smtp.gmail.com login accid1 port 587 password password1
>> machine smtp.gmail.com login accid2 port 587 password password2
>>
>> In your gnus posting styles for the group in question:-
>>
>> 			     (X-Message-SMTP-Method "smtp smtp.gmail.com 587 acc1")
>>
>> Its there somewhere in the gnus manual. But googling for
>> x-message-smtp-method will show a previous thread on this.
>>
>> regards
>>
>> r.
>
> Hi.
>
> I took your advice and it works great. Thanks!
>
> Now my gnus init file look alot cleaner. I was able to discard 
> (defvar smtp-accounts ...)
> (defadvice smtpmail-via-smtp ... )
> (defun change-smtp () ... )
>
> Just for those who tackle with the same problem. My updated
> gnus-posting-style looks like this:
>
> ;; Let Gnus change the "From:" line by looking at current group we are
> ;; in.
> (setq gnus-posting-styles
>       '(("account1"
> 	  (address "account1@gmail.com")
> 	  (name "myname")
> 	  (X-Message-SMTP-Method "smtp smtp.gmail.com 587 account1@gmail.com"))
> 	 ("account2"
> 	  (address "account2@gmail.com")
> 	  (name "myname")
> 	  (X-Message-SMTP-Method "smtp smtp.gmail.com 587 account2@gmail.com")) 
> 	 ("account3"
> 	  (address "account3@gmail.com")
> 	  (name "myname")
> 	  (X-Message-SMTP-Method "smtp smtp.gmail.com 587 account3@gmail.com"))
> 	 ("account4"
> 	  (address "account4@gmail.com")
> 	  (name "myname")
> 	  (X-Message-SMTP-Method "smtp smtp.gmail.com 587 chino.toru@gmail.com"))
> 	 ("account5" (address "account5@hot.ee")
> 	  (name "myname")
> 	  (X-Message-SMTP-Method "smtp mail.hot.ee 25 account5"))
> 	 ))
>
> mihkel
>

Glad it worked for you. Its complicated and somewhat hard to figure out
without examples and especially if you dont know posting styles etc
previously. Next thing to do is set up authfiles as gpg. Keeping
important email passwords (which are often the same as important account
ones) in plain text files is bordering on lunacy. Assuming youre using
Linux then look into gpg-agent and keychain.





  reply	other threads:[~2012-06-28 23:47 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-27 10:25 mihkel
2012-06-27 22:28 ` Katsumi Yamaoka
2012-06-28 15:03   ` mihkel
2012-06-28 17:40     ` Richard Riley
2012-06-28 20:45       ` mihkel
2012-06-28 23:47         ` Richard Riley [this message]
2012-06-29  6:46           ` mihkel
2012-06-29  9:29             ` Richard Riley

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ge1ukz9eyo.fsf@news.eternal-september.org \
    --to=rileyrg@gmail.com \
    --cc=ding@gnus.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).