all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
From: jorge.alfaro-murillo@yale.edu (Jorge A. Alfaro-Murillo)
To: help-gnu-emacs@gnu.org
Subject: Re: How to add multiple email accounts inside gnus
Date: Tue, 03 Nov 2015 14:28:10 -0500	[thread overview]
Message-ID: <87r3k66fxx.fsf@yale.edu> (raw)
In-Reply-To: 8737wnorpb.fsf@gmail.com

Zed writes:

> I have set up the gnus with one gmail account (as follows) 
> 
> (setq gnus-select-method 
>       '(nnimap "gmail" 
> 	       (nnimap-address "imap.gmail.com") 
> (nnimap-server-port 993) (nnimap-stream ssl)))> 
> 
> but is it possible to add other accounts such as hotmail as 
> well? 

Do the same as above with the correct port, but add it to 
gnus-secondary-select-methods:

#+BEGIN_SRC emacs-lisp
  (add-to-list 'gnus-secondary-select-methods 
               '(nnimap "hotmail"
  [...]
#+END_SRC

> (setq smtpmail-default-smtp-server "smtp.gmail.com") (setq 
> smtpmail-smtp-server "smtp.gmail.com") (setq 
> smtpmail-smtp-service 587) 

smtp (the sending part) is a little bit more tricky, since there 
is only one variable. You either have to (1) change 
smtpmail-smtp-server whenever you need the other, or (2) assuming 
they have the same port, add a line in the heading (just like you 
do with "Subject" and "To") with "X-SMTP-Server: 
whatever-the-smtp-address-for-hotmail-is".

You could also make Gmail be able to post from the other service, 
in gmail go to "Settings", then "Accounts and Import", then "Send 
mail as". If you do that, then you only need to change the "From" 
heading, so that it has you hotmail address, Gmail then sends it 
with the correct address. This is the method that I use, but I 
cannot confirm that it works with hotmail.

> (setq sendmail-program "C:/cygwin64/usr/sbin/msmtp")
> (setq message-send-mail-function 
> 'message-send-mail-with-sendmail) 

You shouldn't have to change that.

> (setq message-sendmail-extra-arguments '("-a" "gmail"))

I don't know what that does. I use gmail and do not need it. 

> Also, I am not sure how to attach different accounts for 
> different newsgroup?

I suppose you mean different servers for news. Same as above, 
add-to-list in gnus-secondary-select-methods.

Best,
-- 
Jorge.




  reply	other threads:[~2015-11-03 19:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-11-03 18:36 How to add multiple email accounts inside gnus Zed
2015-11-03 19:28 ` Jorge A. Alfaro-Murillo [this message]
2015-11-03 19:32 ` Filipp Gunbin

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=87r3k66fxx.fsf@yale.edu \
    --to=jorge.alfaro-murillo@yale.edu \
    --cc=help-gnu-emacs@gnu.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.
Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.