multiple Gmail accounts + nnimap + ~/.authinfo
  Home FAQ Contact Sign in
gnu.emacs.gnus only
 
Advanced search
POPULAR GROUPS

more...

gnu.emacs.gnus Profile…
 Up
multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Suno Ano
Date: Apr 9, 2008 08:38

Hi folks,

The versions:
- GNU Emacs 23.0.60.1 (i486-pc-linux-gnu, GTK+ Version 2.12.9) of
2008-04-07 on elegiac, modified by Debian
- No Gnus v0.6

I have a problem using the
- nnimap back end and reading my mails from
- *multiple* Gmail accounts (I have four Gmail accounts)
Show full article (2.47Kb)
12 Comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Ted Zlatanov
Date: Apr 9, 2008 10:28

On Wed, 09 Apr 2008 17:38:45 +0200 Suno Ano googlemail.com> wrote:
SA> ,----[ My ~/.authinfo: ]
SA> | machine imap.gmail.com login @gmail.com password port 993
SA> | machine imap.gmail.com login @gmail.com password port 993
SA> | machine imap.gmail.com login @gmail.com password port 993
SA> | machine imap.gmail.com login @gmail.com password port 993
SA> `----
SA> After starting Gnus, I enter the group buffer, hit B C-k nnimap RET
SA> @gmail.com. Then I subscribe to the groups like INBOX etc.
SA> I repeat the former step for all four of my Gmail accounts. The problem
SA> is, when I quit Gnus and start it again, all INBOX groups show the
SA> emails from my first Gmail account i.e. @gmail.com.

Currently the netrc.el code and everything that uses it only goes by
server+port. In other words, the four lines above look the same to the
netrc.el code so you just get the first one.

I usually set up /etc/hosts aliases for these situations, and that might
work for you until this is resolved.

I can modify netrc.el, but I'm not sure of the best way to do it. Note
that your nnimap method:
Show full article (1.92Kb)
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Suno Ano
Date: Apr 9, 2008 11:30

>| On Wed, 09 Apr 2008 12:31:30 -0500,
>| Ted Zlatanov
>| from the organization of Теодор Златанов @ Cienfuegos
>| who can be reached at: tzz@lifelogs.com
>| (whose comments are cited below with " Ted> "),
>| had this to say in article <86hceb6ikt.fsf@lifelogs.com>
>| in newsgroups gmane.emacs.gnus.user
>| concerning the subject of Re: multiple Gmail accounts + nnimap + ~/.authinfo
>| (see <mailman.10199.1207755910.18990.info-gnus-english@gnu.org> for more details)
Ted> ...Assuming your method is called "gmail1"?
well, it's called "@gmail.com" but then that should not make a
difference to calling it just "gmail1" - yes?
Ted> We could also make 'machine' a more complex field, but I don't
Ted> like that approach.
Why is it you do not like it?
Ted> Any opinions?
Well, before I used nnimap I used nnml as back end. With this back end
and the following snippet it worked like charm. Maybe we could try it
this way for nnimap too? What do others think about it?
Show full article (1.41Kb)
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Ted Zlatanov
Date: Apr 9, 2008 13:17

On Wed, 09 Apr 2008 20:30:44 +0200 Suno Ano googlemail.com> wrote:
>> | On Wed, 09 Apr 2008 12:31:30 -0500,
>> | Ted Zlatanov
>> | from the organization of Теодор Златанов @ Cienfuegos
>> | who can be reached at: tzz@lifelogs.com
>> | (whose comments are cited below with " Ted> "),
>> | had this to say in article <86hceb6ikt.fsf@lifelogs.com>
>> | in newsgroups gmane.emacs.gnus.user
>> | concerning the subject of Re: multiple Gmail accounts + nnimap + ~/.authinfo
>> | (see <mailman.10199.1207755910.18990.info-gnus-english@gnu.org> for more details)
Ted> ...Assuming your method is called "gmail1"?
SA> well, it's called "@gmail.com" but then that should not make a
SA> difference to calling it just "gmail1" - yes?

Right, it was just for the example.
Ted> We could also make 'machine' a more complex field, but I don't
Ted> like that approach.
SA> Why is it you do not like it?
Show full article (2.45Kb)
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Suno Ano
Date: Apr 17, 2008 00:24

>| On Wed, 09 Apr 2008 15:20:16 -0500,
>| Ted Zlatanov
>| from the organization of Теодор Златанов @ Cienfuegos
>| who can be reached at: tzz@lifelogs.com
>| (whose comments are cited below with " Ted> "),
>| had this to say in article <86bq4i7pbz.fsf__45496.0526004017$1207773667$gmane$org@lifelogs.com>
>| in newsgroups gmane.emacs.gnus.user
>| concerning the subject of Re: multiple Gmail accounts + nnimap + ~/.authinfo
>| (see <mailman.10199.1207755910.18990.info-gnus-english@gnu.org> <86hceb6ikt.fsf@lifelogs.com> <mailman.10210.1207766032.18990.info-gnus-english@gnu.org> for more details)
Ted> Mail-source.el and nnimap.el get authentication info in very
Ted> different ways currently. In fact I'm in the process of writing
Ted> auth-source.el (it's about 50%% finished now) which will unite
Ted> mail-source.el, nnimap.el, SMTP, and all the other Gnus
Ted> authentication hooks into one sensible structure. You can look at
Ted> the auth-source.el code to see what I mean. Currently it doesn't
Ted> support multiple accounts per server, so it's good you brought up
Ted> that use case. I've added the necessary code to auth-source.el,
Ted> and will add server support to netrc.el when we agree on how that
Ted> should look in ~/.authinfo..
Show full article (1.56Kb)
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: CHENG Gao
Date: Apr 17, 2008 02:10

*On Thu, 17 Apr 2008 09:24:04 +0200
* Also sprach Suno Ano googlemail.com>:
> Hi Ted, did someone else had an idea how to approach this issue? What
> are we/you going to do now? I can help coding (but not before June I am
> afraid ... /me lacks the time :-/)
>
> I think using nnimap with several gmail accounts is something quite a
> lot people might want to do ...

In your .gnus you can use LABELS for each account, and then in .authinfo
you use label instead of server address. Something like:

in .gnus:
,----
| (nnimap "gmail-account-1"
| (nnimap-server-port 143)
| (nnimap-address "imap.gmail.com")
| (nnimap-list-pattern ("INBOX" "mail/*"))
| (nnimap-authinfo-file "~/.emacs.d/.authinfo"))
`----
(You can add multiple accounts)
Show full article (1.05Kb)
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Ted Zlatanov
Date: Apr 17, 2008 07:50

On Thu, 17 Apr 2008 17:10:33 +0800 CHENG Gao gmail.com> wrote:
CG> *On Thu, 17 Apr 2008 09:24:04 +0200
CG> * Also sprach Suno Ano googlemail.com>:
>> Hi Ted, did someone else had an idea how to approach this issue? What
>> are we/you going to do now? I can help coding (but not before June I am
>> afraid ... /me lacks the time :-/)
>>
>> I think using nnimap with several gmail accounts is something quite a
>> lot people might want to do ...
CG> In your .gnus you can use LABELS for each account, and then in .authinfo
CG> you use label instead of server address. Something like:
Show full article (1.89Kb)
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Suno Ano
Date: Apr 19, 2008 05:59

>| On Thu, 17 Apr 2008 09:53:01 -0500,
>| Ted Zlatanov
>| from the organization of Теодор Златанов @ Cienfuegos
>| who can be reached at: tzz@lifelogs.com
>| (whose comments are cited below with " Ted> "),
>| had this to say in article <86wsmwfs8i.fsf@lifelogs.com>
>| in newsgroups gmane.emacs.gnus.user
>| concerning the subject of Re: multiple Gmail accounts + nnimap + ~/.authinfo
>| (see <mailman.10199.1207755910.18990.info-gnus-english@gnu.org> <86hceb6ikt.fsf@lifelogs.com> <mailman.10210.1207766032.18990.info-gnus-english@gnu.org> <86bq4i7pbz.fsf__45496.0526004017$1207773667$gmane$org@lifelogs.com> <878wzdgd0r.fsf@googlemail.com> <mailman.10475.1208423460.18990.info-gnus-english@gnu.org> for more details)
Ted> Suno, sorry about that. Let me know if Gao's solution works for
Ted> you please.
Hi Ted! Yes Gao's hint was the thing that solved it i.e. using some
"label" per gmail account did the trick.

Thank you Gao and Ted for helping with this issue! Maybe we should adapt
the manual to reflect this sort of configuration so others might not
stubble across it again - yes?
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Date: Apr 19, 2008 11:54

On Sat, Apr 19 2008, Suno Ano wrote:
>>| On Thu, 17 Apr 2008 09:53:01 -0500,
>>| Ted Zlatanov
>>| from the organization of Теодор Златанов @ Cienfuegos
>>| who can be reached at: tzz@lifelogs.com
>>| (whose comments are cited below with " Ted> "),
>>| had this to say in article <86wsmwfs8i.fsf@lifelogs.com>
>>| in newsgroups gmane.emacs.gnus.user
>>| concerning the subject of Re: multiple Gmail accounts + nnimap + ~/.authinfo
>>| (see [full list of References] for more details)

Please stop this nonsense and use a standard attribution *line*, not
an attribution novel.

Bye, Reiner.
--
,,,
(o o)
---ooO-(_)-Ooo--- | PGP key available | http://rsteib.home.pages.de/
no comments
Re: multiple Gmail accounts + nnimap + ~/.authinfo         


Author: Suno Ano
Date: Apr 19, 2008 14:27

A prig is a fellow who is always making you a present of his opinions.
-- George Eliot
no comments
1 2