Re: Identifying multiple imap accounts with new mail in sidebar

2023-02-27 Thread Andy Spiegl
Hi Neubienaut,

> I would like to view my various imap accounts in the sidebar with count
> of new messages so I don't have to reopen each account in mutt (with mutt
> -f 'imap config file') to check for new mail.

I'm trying something similar but there are a few problems with the sidebar.

Please see my mail (Dec 22 and Jan 23) to the mutt list:
 "sidebar inconsistencies or misunderstandings"
Unfortunately nobody replied to my request which either means
that I'm asking for too much or that noone knows a solution.
Or I'm completely misunderstanding some concepts - I hope not.

> Now, what I would like to do is setup a system so that I can determine which
> email accounts have new mail and open them in mutt
For that to work mutt needs open connections to the other accounts.
I haven't figured out yet how to do that right at the start of mutt.
So I'm using this trick: I defined a folder-hook for every account like this:

folder-hook "imaps://USER1@SERVER1/INBOX" push 
'1^mC^uimaps://USER2@SERVER2/INBOX.mutt-trash-pls-ignore^mC^uimaps://USER3@SERVER3/mutt-trash-pls-ignore^mG''

Now when I start mutt for USER1@SERVER1 it jumps to the first message
(which is an empty dummy message I leave in the INBOX) and "saves" it to a
dummy folder on the other accounts.  This makes mutt open imap connections
to the other accounts.  Every once in a while I have to empty the dummy folders.

One advantage of this trick is that mutt can announce new messages in all 
accounts.
Either through the browse-mailboxes command or in the sidebar.
And TAB completion for folders in the other accounts works right from the start 
of mutt.

If anyone knows a better solution I'd be VERY HAPPY to know about it.

Andy

-- 
 Efficiency is intelligent laziness.


Re: Identifying multiple imap accounts with new mail in sidebar

2023-02-26 Thread meine
On Fri, Feb 24, 2023 at 12:59:13PM +, Neubienaut wrote:
> [...]
> I would like to view my various imap accounts in the sidebar with count 
> of new messages so I don't have to reopen each account in mutt (with
> mutt -f 'imap config file') to check for new mail.

I don't have any experience with a sidebar in mutt, but do have a setup
with two accounts (one POP, one IMAP).

I just have to start mutt and can switch between the accounts by
pressing `F2` or `F3` for each of the accounts. The IMAP account updates
automatically when opened, the POP account needs a Shift+G to check for
new mails -- a choice I made to either download new mail and delete them
on the server, or to preserve a copy on the server.

The setting works with folder-hooks in my muttrc that point to files
with settings for both accounts. The `source` in the lines below point
to that file.

Since the IMAP mails are kept on the external server, there is no
directory structure on my box to keep the mails. For the POP account the
default mutt directory structure is used.

The Arch Linux site has very good instructions to make your mutt setup
work! See wiki.archlinux.org/index.php/Mutt

Hope this helps you in making a comfortable setup!

KR,

//meine

* In your muttrc:

## ACCOUNT IMAP [F2]
source "~/.mutt/imap"
folder-hook  'source ~/.mutt/imap'

## ACCOUNT POP [F3]
source "~/.mutt/pop"
folder-hook $folder 'source ~/.mutt/pop'

## Shortcuts
macro index,pager  'source
~/.mutt/imap!'
macro index,pager  'source
~/.mutt/pop!'

* File for each account:

## ACCOUNT POP

##Receive options
set mbox_type = Maildir
set folder = $HOME/mail
set spoolfile = $HOME/mail/inbox
set record = $HOME/mail/sent
set postponed = $HOME/mail/draft
set pop_host = ":@"

##Send options 
set smtp_url = "smtp://@:/"
set smtp_pass = ""
set pop_user = "
set realname = ""
set from = ""
set signature = "~/.signature"

##Connection options
set ssl_force_tls = yes
set ssl_starttls = yes

## Hook -- IMPORTANT!
account-hook $folder "set pop_user=
pop_pass="

/EOF


Identifying multiple imap accounts with new mail in sidebar

2023-02-24 Thread Neubienaut

Hello all,
Any thoughts or suggestions on how to accomplish the next step in my 
mutt setup process?
I would like to view my various imap accounts in the sidebar with count 
of new messages so I don't have
to reopen each account in mutt (with mutt -f 'imap config file') to 
check for new mail.



LONGER EXPLANATION

I recently decided to revisit mutt as my email client after about a ten 
year hiatus from mutt.
I have been having fun over the past week setting up various config 
files and such.


I currently have multiple mutt config files (muttrc) for the different 
imap accounts I have.

I use aliases in bash to open up the different accounts
So, in bash:
gmn = will open neubienaut gmail imap account (mutt -F config file 1)
prn = will open neubienaut protonmail account (mutt -F config file 2)

I have the sidebar setup so that the account's sub folders are visible 
in the sidebar when a particular account is opened

set imap_check_subscribed = yes
set sidebar_sort_method=alpha
set sidebar_folder_indent = yes

Now, what I would like to do is setup a system so that I can determine 
which email accounts have new mail and open them in mutt
so that I don't have to open each email account beforehand, in a 
separate script,  to determine which accounts have new mail and

which accounts do not have new mail.
I have 5+ email accounts so it is a bit cumbersome to open each account.

An example of what I am trying to achieve would be Thunderbird that has 
a list of all my email accounts in the sidebar
and let's me know which accounts have new email except I don't 
necessarily want all the email accounts and subfolders to

show up in the sidebar at the same time.


For the next step in my setup process I would like to be able to either

1.
 a. show all imap accounts in sidebar with number of new messages.
 b. then, by selecting a particular imap account with new email in sidebar
 c. I can then go to the sub-folder view for that account and check the 
new mail


2
 a. Have a script in bash that can poll the various imap accounts and 
check for new email.
 b. find the first imap account with new email and open that account in 
mutt
 c. when mutt is closed, rerun the script to check for remaining 
accounts with new mail

 d. open the next account with new mail
 e. repeat process until and accounts with new mail have been viewed

3 Maybe some third idea for checking all my accounts I haven't thought of?



Any thoughts or suggestions on how to accomplish the next step in my 
mutt setup process?


TIA





Re: multiple IMAP accounts on one server?

2023-01-16 Thread raf via Mutt-users
On Sun, Jan 15, 2023 at 08:58:19PM +0100, Matěj Cepl  wrote:

> Hi,
> 
> I am looking for the terminal-based MUA which would be able to
> work with my email needs. However, for various reasons I really
> need all my emails stay on multiple IMAP accounts (no local
> emails if possible). I have started with mutt as it is the
> client I know best, but I am not married to it, if you know
> about anything better (Alpine?, notmuch?, anything else) which
> could help me, then I am all ears.

Have a look at neomutt. It's based on mutt, and might or might
not be different in relation to account hooks.

> account-hook .*localhost 'set imap_user=matej imap_pass=secret1 \
> from="Matěj Cepl "
> folder=imap://localhost.localdomain \
> trash=+Trash postponed=+Drafts'
> # account-hook mcepl 'set imap_user=mc...@cepl.eu imap_pass="secret2" \
> # from="Matěj Cepl " \
> # folder=imaps://redcrew.org trash=+Trash postponed=+Drafts'
> account-hook .*redcrew.org 'set imap_user="ma...@ceplovi.cz" \
> imap_pass= "secret3" \
> from="Matěj Cepl " \
> folder=imaps://redcrew.org trash=+Trash postponed=+Drafts'
> account-hook .*suse.de 'set imap_user=mcepl@Thunderbird \
> imap_pass= "secret4" \
> postponed=+INBOX/Drafts from="Matěj Cepl " \
> trash=+INBOX/Trash'
> 
> The problem is obviously mc...@cepl.eu account.
> 
> * Is it possible to have two account hooks directed against one
>   IMAP server?

Kind of. I found this:

  [mutt] Multiple email accounts using hooks
  
https://nixtricks.wordpress.com/2010/05/20/mutt-multiple-email-accounts-using-hooks/

It has an initial account-hook matching . that unsets things,
followed by other account-hooks that sets them depending on
the account.

So, multiple account-hook directives can match the same account.
It just depends on the regular expressions used. But that might
not be useful to you. I'm not sure why you want different
account-hooks for the same account.

If you want two different sets of parameters for the same account
(does that even make sense?), then you might need to put them in
different rc files, and perhaps create key bindings to load the one
you want when you want to change.

> * What EXACTLY are possible values of the first parameter of
>   account-hook. Does it have to be domain name of the server, or
>   could it be some random string (as shown here in the commented
>   out account-hook)?

Good question. It's not clear from just the account-hook entry in
muttrc(5). From the webpage mentioned above, it looks like the
regexp needs to match the imap URI
(e.g., 'imaps://us...@imap.gmail.com/').

> * Is there some patch somewhere, which would support some more
>   grown-up version of the accounts settings? I would like to have
>   something like
> 
>   account work { \
> imap_server = imap.suse.de \
> imap_user = mcepl@Thunderbird \
> imap_pass = secret4 \
> ... { any other mutt settings }
>   }
> 
>   account floss { \
> imap_server = redcrew.org \
> imap_user = mc...@cepl.eu \
> imap_pass = secret2 \
> ... { any other mutt settings }
>   }
> 
>   and then I would run
> 
>   $ mutt -C work
> 
>   (C as aCcount)
> 
>   and when inside of mutt I could refer to the other account with
>   something like
> 
>   #floss/INBOX/somewhere
> 
> Anybody heard about something like this?

No, but the same thing can be achieved with alternate muttrc files
and the -F option. When you run "mutt -F work" or "mutt -F floss",
the work and floss rc files can contain their specific imap settings,
and then source a common rc file with everything else.

For saving to the other account, macros would help.

If you really like your config syntax above, you could probably
write a little tool that "compiled" it into muttrc syntax.

> Best,
> Matěj

cheers,
raf



Re: multiple IMAP accounts on one server?

2023-01-15 Thread Patrick Shanahan
* Matěj Cepl  [01-15-23 15:00]:
> Hi,
> 
> I am looking for the terminal-based MUA which would be able to
> work with my email needs. However, for various reasons I really
> need all my emails stay on multiple IMAP accounts (no local
> emails if possible). I have started with mutt as it is the
> client I know best, but I am not married to it, if you know
> about anything better (Alpine?, notmuch?, anything else) which
> could help me, then I am all ears.
> 
> account-hook .*localhost 'set imap_user=matej imap_pass=secret1 \
> from="Matěj Cepl "
> folder=imap://localhost.localdomain \
> trash=+Trash postponed=+Drafts'
> # account-hook mcepl 'set imap_user=mc...@cepl.eu imap_pass="secret2" \
> # from="Matěj Cepl " \
> # folder=imaps://redcrew.org trash=+Trash postponed=+Drafts'
> account-hook .*redcrew.org 'set imap_user="ma...@ceplovi.cz" \
> imap_pass= "secret3" \
> from="Matěj Cepl " \
> folder=imaps://redcrew.org trash=+Trash postponed=+Drafts'
> account-hook .*suse.de 'set imap_user=mcepl@Thunderbird \
> imap_pass= "secret4" \
> postponed=+INBOX/Drafts from="Matěj Cepl " \
> trash=+INBOX/Trash'
> 
> The problem is obviously mc...@cepl.eu account.
> 
> * Is it possible to have two account hooks directed against one
>   IMAP server?

certainly, I have two IMAP accounts regestered with googlemail but with
different names and I use mutt for many years.

but I download my mail to my local server for access.

 [...] 

[-- Error: unable to create PGP subprocess! --]
:: waste




-- 
(paka)Patrick Shanahan   Plainfield, Indiana, USA  @ptilopteri
http://en.opensuse.orgopenSUSE Community Memberfacebook/ptilopteri
Photos: http://wahoo.no-ip.org/piwigo   paka @ IRCnet oftc


multiple IMAP accounts on one server?

2023-01-15 Thread Matěj Cepl
Hi,

I am looking for the terminal-based MUA which would be able to
work with my email needs. However, for various reasons I really
need all my emails stay on multiple IMAP accounts (no local
emails if possible). I have started with mutt as it is the
client I know best, but I am not married to it, if you know
about anything better (Alpine?, notmuch?, anything else) which
could help me, then I am all ears.

account-hook .*localhost 'set imap_user=matej imap_pass=secret1 \
from="Matěj Cepl "
folder=imap://localhost.localdomain \
trash=+Trash postponed=+Drafts'
# account-hook mcepl 'set imap_user=mc...@cepl.eu imap_pass="secret2" \
# from="Matěj Cepl " \
# folder=imaps://redcrew.org trash=+Trash postponed=+Drafts'
account-hook .*redcrew.org 'set imap_user="ma...@ceplovi.cz" \
imap_pass= "secret3" \
from="Matěj Cepl " \
folder=imaps://redcrew.org trash=+Trash postponed=+Drafts'
account-hook .*suse.de 'set imap_user=mcepl@Thunderbird \
imap_pass= "secret4" \
postponed=+INBOX/Drafts from="Matěj Cepl " \
trash=+INBOX/Trash'

The problem is obviously mc...@cepl.eu account.

* Is it possible to have two account hooks directed against one
  IMAP server?

* What EXACTLY are possible values of the first parameter of
  account-hook. Does it have to be domain name of the server, or
  could it be some random string (as shown here in the commented
  out account-hook)?

* Is there some patch somewhere, which would support some more
  grown-up version of the accounts settings? I would like to have
  something like

  account work { \
imap_server = imap.suse.de \
imap_user = mcepl@Thunderbird \
imap_pass = secret4 \
... { any other mutt settings }
  }

  account floss { \
imap_server = redcrew.org \
imap_user = mc...@cepl.eu \
imap_pass = secret2 \
... { any other mutt settings }
  }

  and then I would run

  $ mutt -C work

  (C as aCcount)

  and when inside of mutt I could refer to the other account with
  something like

  #floss/INBOX/somewhere

Anybody heard about something like this?

Best,

Matěj

-- 
https://matej.ceplovi.cz/blog/, @mcepl@floss.social
GPG Finger: 3C76 A027 CA45 AD70 98B5  BC1D 7920 5802 880B C9D8

The state is the great fictitious entity by which everyone seeks
to live at the expense of everyone else.
  -- Frederick Bastiat

OpenPGP_0x79205802880BC9D8.asc
Description: OpenPGP public key


OpenPGP_signature
Description: OpenPGP digital signature


Re: Change list of folders accessible via 'c' or 'y' for multiple IMAP accounts

2012-02-24 Thread Oon-Ee Ng
On Thu, Feb 23, 2012 at 3:11 PM, Oon-Ee Ng ngoonee.t...@gmail.com wrote:
 Hi, I'm using dovecot locally on my laptop (with offlineimap) for
 multiple accounts (name and name2). Just setting mutt up now for that
 (previously using evolution).

 I'm using folder-hooks to set the following to the appropriate values:-
 set from = ngoonee.t...@gmail.com
 set imap_user=name
 set imap_pass=password
 set realname = Ng Oon-Ee
 set folder=imap://name@localhost/
 set spoolfile=+/

 for both accounts

 Works fine for the 'default' account which I start in. However when I
 change account using c - imap://name2@localhost, the folders list
 expands to include all the folders in account 'name' and 'name2' while
 the IMAP folders list (accessible using 'y') shows the folders of the
 previous account (name).

 I've tried using unmailboxes, but the lists don't change in content
 (trying to access folders from the wrong account gives a 'does not
 exist' error though). Am stumped at the moment, what am I missing?

Trying to script workarounds using macros and having problems with a
peculiar (to my mind) behaviour.

In the pager and index, change-folder suggests a path, but if I
start typing i-m-a-p-:-/-/ it will show imap://

However, in the browser, change-folder appends what I type to the
current path, so for example it will first show:-

Chdir to: imap://name@localhost/

and after calling my macro which simply runs
change-folderimap://name2@localhost the result will be
Chdir to: imap://name@localhost/hange-folderimap://name2@localhost

It seems to me to be buggy in two ways, first that change-folder is
spelt out in that way, and secondly that the default behaviour is
auto-appending. Am I doing something wrong or is this a bug?


Change list of folders accessible via 'c' or 'y' for multiple IMAP accounts

2012-02-22 Thread Oon-Ee Ng
Hi, I'm using dovecot locally on my laptop (with offlineimap) for
multiple accounts (name and name2). Just setting mutt up now for that
(previously using evolution).

I'm using folder-hooks to set the following to the appropriate values:-
set from = ngoonee.t...@gmail.com
set imap_user=name
set imap_pass=password
set realname = Ng Oon-Ee
set folder=imap://name@localhost/
set spoolfile=+/

for both accounts

Works fine for the 'default' account which I start in. However when I
change account using c - imap://name2@localhost, the folders list
expands to include all the folders in account 'name' and 'name2' while
the IMAP folders list (accessible using 'y') shows the folders of the
previous account (name).

I've tried using unmailboxes, but the lists don't change in content
(trying to access folders from the wrong account gives a 'does not
exist' error though). Am stumped at the moment, what am I missing?


multiple IMAP accounts

2011-05-09 Thread David Froger
Hy,

I'm trying to set up multiple IMAP acounts. My problem is about
switching between servers.

I've read some documentation on the web, especially this one:
http://wiki.mutt.org/?MuttGuide/UseIMAP

The important lines in my .muttrc are :

set header_cache = ~/.mutt_header_cache
set message_cachedir = ~/.mutt_msg_cache
set imap_authenticators = login
set imap_passive = no
set imap_check_subscribed = yes
set imap_list_subscribed = yes
set ssl_starttls = yes

account-hook . 'unset preconnect imap_user'

account-hook imaps://imap.gmail.com:993 ' \
    set imap_user = us...@gmail.com \
    spoolfile = imaps://imap.gmail.com:993 \
    '
folder-hook imaps://imap.gmail.com:993 ' \
    set folder = imaps://imap.gmail.com:993 \
    smtp_url = smtps://us...@smtp.gmail.com:465 \
    '
account-hook imaps://zimbra.HOST2 ' \
    set imap_user = USER2 \
    spoolfile = imaps://zimbra.HOST2 \
    '
folder-hook imaps://zimbra.HOST2 ' \
    set folder = imaps://zimbra.HOST2 \
    smtp_url = smtp://USER2@smtp.HOST2 \


When I run mutt, mutt ask me the password for zimbra.HOST2, then
connects to zimbra.HOST2 (I can read the mails) but I don't know how
to access my Gmail account.
Pressing the key y give me these choices :

1   0 imaps://zimbra.HOST2/Drafts
2   0 imaps://zimbra.HOST2/Sent

Of course, I've tested the two accounts with mutt independently, they
both works.
I've also tried to use 'mailboxes = =INBOX =...'.
I'm using Mutt 1.5.20

Thank you for any help or suggestion,

Best,


Re: multiple IMAP accounts

2011-05-09 Thread Marco Giusti
On Mon, May 09, 2011 at 08:55:21AM +0200, David Froger wrote:
[...]
 When I run mutt, mutt ask me the password for zimbra.HOST2, then
 connects to zimbra.HOST2 (I can read the mails) but I don't know how
 to access my Gmail account.

use `mailboxes` command so you can switch between in browser.

mailboxes imaps://imap.gmail.com/
mailboxes imaps://zimbra.HOST2/

m.



-- 
C'è un'ape che se posa
su un bottone di rosa:
lo succhia e se ne va...
Tutto sommato, la felicità
è una piccola cosa.
-- Trilussa, Felicità


Re: multiple IMAP accounts

2011-05-09 Thread David Froger
It's working, thanks a lot!

with:
account-hook imaps://imap.gmail.com:993 (...)
folder-hook imaps://imap.gmail.com:993 (...)

this works:
mailboxes imaps://imap.gmail.com:993

but this does not work (mutt ask my username/passwd, but can't connect):
mailboxes imaps://imap.gmail.com/

I think it was my problem in previous tests.



2011/5/9 Marco Giusti marco.giu...@gmail.com:
 On Mon, May 09, 2011 at 08:55:21AM +0200, David Froger wrote:
 [...]
 When I run mutt, mutt ask me the password for zimbra.HOST2, then
 connects to zimbra.HOST2 (I can read the mails) but I don't know how
 to access my Gmail account.

 use `mailboxes` command so you can switch between in browser.

        mailboxes imaps://imap.gmail.com/
        mailboxes imaps://zimbra.HOST2/

 m.



 --
 C'è un'ape che se posa
 su un bottone di rosa:
 lo succhia e se ne va...
 Tutto sommato, la felicità
 è una piccola cosa.
                -- Trilussa, Felicità



Re: multiple IMAP accounts

2011-05-09 Thread Marco Giusti
On Mon, May 09, 2011 at 11:37:41AM +0200, David Froger wrote:
 It's working, thanks a lot!
 
 with:
 account-hook imaps://imap.gmail.com:993 (...)
 folder-hook imaps://imap.gmail.com:993 (...)
 
 this works:
 mailboxes imaps://imap.gmail.com:993
 
 but this does not work (mutt ask my username/passwd, but can't connect):
 mailboxes imaps://imap.gmail.com/
 
 I think it was my problem in previous tests.

I don't know mutt internals and this is just a guess but I think that
the problem is the explicit imap port in the _account-hook_ and the final
slash in the _mailboxes_ command. These are the relative lines i had:


account-hook imaps://imap\.gmail\.com/ 'set 
imap_user=marco.giu...@gmail.com'
account-hook imaps://imap\.gmail\.com/ 'set imap_pass=cucu'
mailboxes imaps://imap.gmail.com/

m.

 2011/5/9 Marco Giusti marco.giu...@gmail.com:
  On Mon, May 09, 2011 at 08:55:21AM +0200, David Froger wrote:
  [...]
  When I run mutt, mutt ask me the password for zimbra.HOST2, then
  connects to zimbra.HOST2 (I can read the mails) but I don't know how
  to access my Gmail account.
 
  use `mailboxes` command so you can switch between in browser.
 
         mailboxes imaps://imap.gmail.com/
         mailboxes imaps://zimbra.HOST2/

-- 
Nessuno come me si è creato una società reale evocando delle ombre; al
punto che la vita dei miei ricordi assorbe il sentimento della mia
vita reale.
-- René de Chateaubriand, Mémoires d'Outre-tombe


Multiple IMAP accounts and change-dir autocompletion

2010-09-07 Thread Max Arnold
Hello all,

I have multiple IMAP accounts (configuration is below) and mutt does not
reread remote directory list when I switch between mailboxes. For example:

- I open personal mailbox, press change-dir TAB and mutt shows remote folders
for that account

- then I swith to second account, again do change-dir TAB, but still see
remote folders from first account

So basically mutt caches first opened remote folder list and displays it every
time. Any ideas on how to fix this?

# 

mailboxes = imaps://perso...@imap.gmail.com:993/
mailboxes = imaps://w...@imap.gmail.com:993/

account-hook imaps://perso...@imap.gmail.com:993/ \
'set imap_user = perso...@gmail.com'

account-hook imaps://w...@imap.gmail.com:993/ \
'set imap_user = w...@gmail.com'

folder-hook imaps://perso...@imap.gmail.com:993 \
'set folder = imaps://perso...@imap.gmail.com:993/ \
smtp_url = smtps://perso...@smtp.gmail.com:465 \
from = perso...@gmail.com'

folder-hook imaps://w...@imap.gmail.com:993/ \
'set folder = imaps://w...@imap.gmail.com:993 \
smtp_url = smtps://w...@smtp.gmail.com:465 \
from = w...@gmail.com'

set folder = imaps://perso...@imap.gmail.com:993/

set spoolfile = =INBOX
set postponed = =[Gmail]/Drafts
unset record

macro index f1 change-folderimaps://perso...@imap.gmail.com:993/enter
macro index f2 change-folderimaps://w...@imap.gmail.com:993/enter


Re: Multiple IMAP accounts and change-dir autocompletion

2010-09-07 Thread Rado S
=- Max Arnold wrote on Wed  8.Sep'10 at  1:35:21 +0700 -=

 mutt does not reread remote directory list when I switch between
 mailboxes. For example:
 
 - I open personal mailbox, press change-dir TAB and mutt shows remote 
 folders
 for that account
 
 - then I swith to second account, again do change-dir TAB, but still see
 remote folders from first account
 
 So basically mutt caches first opened remote folder list and displays it every
 time. Any ideas on how to fix this?

This has nothing to do with 2 IMAP accounts, but with how
change-dir and TAB interact.
See Wiki / Guide / Actions for details.

-- 
© Rado S. -- You must provide YOUR effort for your goal!
EVERY effort counts: at least to show your attitude.
You're responsible for ALL you do: you get what you give.


Re: Multiple IMAP accounts

2010-03-22 Thread Paul Tansom
** Peng shallp...@gmail.com [2010-03-20 22:31]:
 On 21:18 Sat 20 Mar , Paul Tansom wrote:
  ** Brendan Cully bren...@kublai.com [2010-03-20 20:53]:
  
  Brilliant, thanks, that's exactly what I was looking for. It's my own fault 
  for
  having so many mail accounts that it now takes a while to connect to them 
  all!!
 
 Actually you may find this frustrating sometimes if your internet
 connection is not very good
** end quote [Peng]

That's not too much of a problem here, since the connection is to a Dovecot
IMAP server on my local LAN mostly, and I SSH in to check mail remotely. That
said I am connecting to 10 accounts for various reasons at the moment!

-- 
Paul Tansom | Aptanet Ltd. | http://www.aptanet.com/ | 023 9238 0001
==
Registered in England  |  Company No: 4905028  |  Registered Office:
Crawford House, Hambledon Road, Denmead, Waterlooville, Hants, PO7 6NU


Multiple IMAP accounts

2010-03-20 Thread Paul Tansom
I've been using Mutt for a good few years now, but only started using it over
IMAP a year or so ago and now I've started using multiple IMAP accounts with
it. Setting this up was straight forward enough, and I can cycle through
mailboxes with new mail in quite happily, but only if I have already checked
mail once. What I'm trying to do, and haven't yet worked out how, is connect to
all the IMAP mail accounts when I first start Mutt, so Mutt knows which ones
have new mail in without having to manually change into each one first. Can
anyone point me to some good references for this, I've not managed to spot what
I'm looking for with Google or on the Mutt Wiki so far.

Another thing I'll be looking at is a means to save me typing in the full
details of each mail account in order to switch between them. I'm particularly
keen on this since they are all on the same server and each account name is the
email address and things get quite long winded even with tab completion! I'm
thinking that something along the lines of a macro or a bind line in my muttrc
file should do the trick here, but since I'm typing if anyone has a pointer it
may save me some time :)

-- 
Paul Tansom | Aptanet Ltd. | http://www.aptanet.com/ | 023 9238 0001
==
Registered in England  |  Company No: 4905028  |  Registered Office:
Crawford House, Hambledon Road, Denmead, Waterlooville, Hants, PO7 6NU


Re: Multiple IMAP accounts

2010-03-20 Thread Jan Kadijk
On Sat, Mar 20, 2010 at 06:01:19PM +, Paul Tansom wrote:
 I've been using Mutt for a good few years now, but only started using it over
 IMAP a year or so ago and now I've started using multiple IMAP accounts with
 it. Setting this up was straight forward enough, and I can cycle through
 mailboxes with new mail in quite happily, but only if I have already checked
 mail once. What I'm trying to do, and haven't yet worked out how, is connect 
 to
 all the IMAP mail accounts when I first start Mutt, so Mutt knows which ones
 have new mail in without having to manually change into each one first. Can
 anyone point me to some good references for this, I've not managed to spot 
 what
 I'm looking for with Google or on the Mutt Wiki so far.
 
 Another thing I'll be looking at is a means to save me typing in the full
 details of each mail account in order to switch between them. I'm particularly
 keen on this since they are all on the same server and each account name is 
 the
 email address and things get quite long winded even with tab completion! I'm
 thinking that something along the lines of a macro or a bind line in my muttrc
 file should do the trick here, but since I'm typing if anyone has a pointer it
 may save me some time :)
 
 -- 
 Paul Tansom | Aptanet Ltd. | http://www.aptanet.com/ | 023 9238 0001
 ==
 Registered in England  |  Company No: 4905028  |  Registered Office:
 Crawford House, Hambledon Road, Denmead, Waterlooville, Hants, PO7 6NU

The best solution I know of, is to use OfflineIMAP. It can sync multiple
IMAP accounts to Maildirs. It works great for me. Google for a tutorial
:)

-- Jan



Re: Multiple IMAP accounts

2010-03-20 Thread Brendan Cully
On Saturday, 20 March 2010 at 18:01, Paul Tansom wrote:
 I've been using Mutt for a good few years now, but only started using it over
 IMAP a year or so ago and now I've started using multiple IMAP accounts with
 it. Setting this up was straight forward enough, and I can cycle through
 mailboxes with new mail in quite happily, but only if I have already checked
 mail once. What I'm trying to do, and haven't yet worked out how, is connect 
 to
 all the IMAP mail accounts when I first start Mutt, so Mutt knows which ones
 have new mail in without having to manually change into each one first. Can
 anyone point me to some good references for this, I've not managed to spot 
 what
 I'm looking for with Google or on the Mutt Wiki so far.

unset $imap_passive to automatically connect to any mailbox you've
added to the mailboxes list with the 'mailboxes' command.

 Another thing I'll be looking at is a means to save me typing in the full
 details of each mail account in order to switch between them. I'm particularly
 keen on this since they are all on the same server and each account name is 
 the
 email address and things get quite long winded even with tab completion! I'm
 thinking that something along the lines of a macro or a bind line in my muttrc
 file should do the trick here, but since I'm typing if anyone has a pointer it
 may save me some time :)

yes, binding a macro should help here. e.g.,

macro index I 'change-folderimap://f...@bar/INBOX'



Re: Multiple IMAP accounts

2010-03-20 Thread Paul Tansom
** Brendan Cully bren...@kublai.com [2010-03-20 20:53]:
 On Saturday, 20 March 2010 at 18:01, Paul Tansom wrote:
  I've been using Mutt for a good few years now, but only started using it 
  over
  IMAP a year or so ago and now I've started using multiple IMAP accounts with
  it. Setting this up was straight forward enough, and I can cycle through
  mailboxes with new mail in quite happily, but only if I have already checked
  mail once. What I'm trying to do, and haven't yet worked out how, is 
  connect to
  all the IMAP mail accounts when I first start Mutt, so Mutt knows which ones
  have new mail in without having to manually change into each one first. Can
  anyone point me to some good references for this, I've not managed to spot 
  what
  I'm looking for with Google or on the Mutt Wiki so far.
 
 unset $imap_passive to automatically connect to any mailbox you've
 added to the mailboxes list with the 'mailboxes' command.

Brilliant, thanks, that's exactly what I was looking for. It's my own fault for
having so many mail accounts that it now takes a while to connect to them all!!

There's so many things you can do with Mutt that in spite of having started
using it some time in 2000, there's still plenty to discover :)

  Another thing I'll be looking at is a means to save me typing in the full
  details of each mail account in order to switch between them. I'm 
  particularly
  keen on this since they are all on the same server and each account name is 
  the
  email address and things get quite long winded even with tab completion! I'm
  thinking that something along the lines of a macro or a bind line in my 
  muttrc
  file should do the trick here, but since I'm typing if anyone has a pointer 
  it
  may save me some time :)
 
 yes, binding a macro should help here. e.g.,
 
 macro index I 'change-folderimap://f...@bar/INBOX'

I shall have to have a play and see what I can come up with to save some typing.
** end quote [Brendan Cully]

-- 
Paul Tansom | Aptanet Ltd. | http://www.aptanet.com/ | 023 9238 0001
==
Registered in England  |  Company No: 4905028  |  Registered Office:
Crawford House, Hambledon Road, Denmead, Waterlooville, Hants, PO7 6NU


Re: Multiple IMAP accounts

2010-03-20 Thread Paul Tansom
** Jan Kadijk flappie1...@gmail.com [2010-03-20 19:33]:
 On Sat, Mar 20, 2010 at 06:01:19PM +, Paul Tansom wrote:
  I've been using Mutt for a good few years now, but only started using it 
  over
  IMAP a year or so ago and now I've started using multiple IMAP accounts with
  it. Setting this up was straight forward enough, and I can cycle through
  mailboxes with new mail in quite happily, but only if I have already checked
  mail once. What I'm trying to do, and haven't yet worked out how, is 
  connect to
  all the IMAP mail accounts when I first start Mutt, so Mutt knows which ones
  have new mail in without having to manually change into each one first. Can
  anyone point me to some good references for this, I've not managed to spot 
  what
  I'm looking for with Google or on the Mutt Wiki so far.
snip
 The best solution I know of, is to use OfflineIMAP. It can sync multiple
 IMAP accounts to Maildirs. It works great for me. Google for a tutorial
 :)
** end quote [Jan Kadijk]

I've looked at that for backup, but given the number of different machines I
connect from it could cause a few problems for my setup, particularly with disk
space since between the accounts I have in excess of 6G of mail folders (mostly
archives) that I connect to.

-- 
Paul Tansom | Aptanet Ltd. | http://www.aptanet.com/ | 023 9238 0001
==
Registered in England  |  Company No: 4905028  |  Registered Office:
Crawford House, Hambledon Road, Denmead, Waterlooville, Hants, PO7 6NU


Re: Multiple IMAP accounts

2010-03-20 Thread Peng
On 21:18 Sat 20 Mar , Paul Tansom wrote:
 ** Brendan Cully bren...@kublai.com [2010-03-20 20:53]:
 
 Brilliant, thanks, that's exactly what I was looking for. It's my own fault 
 for
 having so many mail accounts that it now takes a while to connect to them 
 all!!


Actually you may find this frustrating sometimes if your internet
connection is not very good

Peng


Re: Mutt and multiple imap accounts

2010-02-22 Thread Horacio Sanson
On Sat, Feb 20, 2010 at 02:57:41PM +0100, Zeerak Waseem wrote:
 Hey,
 
 I'm having some difficulties with mutt and multiple imaps; I've been
 trying to set it up for my private mail and my uni mail, but I can't seem
 to get it to work. I've been following two entries from the wiki (mainly)
 this (http://wiki.mutt.org/?MuttGuide/UseIMAP) and this
 (http://wiki.mutt.org/?UserStory/GmailMultiIMAP), if I purely follow the
 first link, then mutt responds with there being no maildir.
 If I purely follow the second link then it recognizes the maildir, but it
 shows that there are no mailboxes.
 A finesse to this is that my uni mail has a different ending from the imap
 server (the other is a gmail account). Could someone help me point out the
 flaws in my configuration?
 
 # Base hook to reset account variables to known state before activating
 new ones
   account-hook . 'unset preconnect imap_user imap_pass imap_authenticators;
 set ssl_starttls=ask-yes'
 
   account-hook imaps://imap.gmail.com:993/ 'set imap_user=Gmail-user
 imap_pass=Pass'
   folder-hook imaps://imap.gmail.com:993/ 'set
 folder=imaps://imap.gmail.com/INBOX record=+Sent from=My Name
 gmail-u...@gmail.com'
 
   account-hook imaps://uni-imap-server.com/ 'set imap_user=Uni-user
 imap_pass=Pass2'
   folder-hook imaps://uni-imap-server.com/ 'set
 folder=imaps://uni-imap-server.com/INBOX record=+Sent from=My Name
 uni-m...@uni-mail-address.com'
 
 If I add a folder and a spoolfile line (independent of the hooks) then
 this setup works, but would I need to set a spoolfile and a folder for
 both accounts? I think I tried it, but I'm not quite certain.

The folder and spoolfile you set would be your defaults that get open
when you start mutt. You only need to set these for one of your
accounts.

A few days back I posted in this mailing list my configuration to handle 
multiple Gmail
accounts. Search the archives for a subject like Simple Mutt with Eee
PC 701. You may find it useful.

 
 Any help would be appreciated :-)
 
 
 -- 
 Zeerak

-- 
regards,
Horacio Sanson


Re: Mutt and multiple imap accounts

2010-02-22 Thread Zeerak Mustafa Waseem
On Mon, Feb 22, 2010 at 09:42:19AM +0900, Horacio Sanson wrote:
 On Sat, Feb 20, 2010 at 02:57:41PM +0100, Zeerak Waseem wrote:
  Hey,
  
  I'm having some difficulties with mutt and multiple imaps; I've been
  trying to set it up for my private mail and my uni mail, but I can't seem
  to get it to work. I've been following two entries from the wiki (mainly)
  this (http://wiki.mutt.org/?MuttGuide/UseIMAP) and this
  (http://wiki.mutt.org/?UserStory/GmailMultiIMAP), if I purely follow the
  first link, then mutt responds with there being no maildir.
  If I purely follow the second link then it recognizes the maildir, but it
  shows that there are no mailboxes.
  A finesse to this is that my uni mail has a different ending from the imap
  server (the other is a gmail account). Could someone help me point out the
  flaws in my configuration?
  
  # Base hook to reset account variables to known state before activating
  new ones
account-hook . 'unset preconnect imap_user imap_pass imap_authenticators;
  set ssl_starttls=ask-yes'
  
account-hook imaps://imap.gmail.com:993/ 'set imap_user=Gmail-user
  imap_pass=Pass'
folder-hook imaps://imap.gmail.com:993/ 'set
  folder=imaps://imap.gmail.com/INBOX record=+Sent from=My Name
  gmail-u...@gmail.com'
  
account-hook imaps://uni-imap-server.com/ 'set imap_user=Uni-user
  imap_pass=Pass2'
folder-hook imaps://uni-imap-server.com/ 'set
  folder=imaps://uni-imap-server.com/INBOX record=+Sent from=My Name
  uni-m...@uni-mail-address.com'
  
  If I add a folder and a spoolfile line (independent of the hooks) then
  this setup works, but would I need to set a spoolfile and a folder for
  both accounts? I think I tried it, but I'm not quite certain.
 
 The folder and spoolfile you set would be your defaults that get open
 when you start mutt. You only need to set these for one of your
 accounts.
 
 A few days back I posted in this mailing list my configuration to handle 
 multiple Gmail
 accounts. Search the archives for a subject like Simple Mutt with Eee
 PC 701. You may find it useful.
 
  
  Any help would be appreciated :-)
  
  
  -- 
  Zeerak
 
 -- 
 regards,
 Horacio Sanson

Ah yes, I found it :-) And I've gotten it working now :-)

I also created a blog to document how to set it up, and anything else useful I 
needed. :-)

-- 
Zeerak Waseem


pgpwNeNXoRaUV.pgp
Description: PGP signature


Mutt and multiple imap accounts

2010-02-20 Thread Zeerak Waseem

Hey,

I'm having some difficulties with mutt and multiple imaps; I've been
trying to set it up for my private mail and my uni mail, but I can't seem
to get it to work. I've been following two entries from the wiki (mainly)
this (http://wiki.mutt.org/?MuttGuide/UseIMAP) and this
(http://wiki.mutt.org/?UserStory/GmailMultiIMAP), if I purely follow the
first link, then mutt responds with there being no maildir.
If I purely follow the second link then it recognizes the maildir, but it
shows that there are no mailboxes.
A finesse to this is that my uni mail has a different ending from the imap
server (the other is a gmail account). Could someone help me point out the
flaws in my configuration?

# Base hook to reset account variables to known state before activating
new ones
  account-hook . 'unset preconnect imap_user imap_pass imap_authenticators;
set ssl_starttls=ask-yes'

  account-hook imaps://imap.gmail.com:993/ 'set imap_user=Gmail-user
imap_pass=Pass'
  folder-hook imaps://imap.gmail.com:993/ 'set
folder=imaps://imap.gmail.com/INBOX record=+Sent from=My Name
gmail-u...@gmail.com'

  account-hook imaps://uni-imap-server.com/ 'set imap_user=Uni-user
imap_pass=Pass2'
  folder-hook imaps://uni-imap-server.com/ 'set
folder=imaps://uni-imap-server.com/INBOX record=+Sent from=My Name
uni-m...@uni-mail-address.com'

If I add a folder and a spoolfile line (independent of the hooks) then
this setup works, but would I need to set a spoolfile and a folder for
both accounts? I think I tried it, but I'm not quite certain.

Any help would be appreciated :-)


--
Zeerak


Re: Mutt and multiple imap accounts

2010-02-20 Thread Chuck Smith
On Sat, Feb 20, 2010 at 02:57:41PM +0100, Zeerak Waseem wrote:
 Hey,
 
 I'm having some difficulties with mutt and multiple imaps; I've been
 trying to set it up for my private mail and my uni mail, but I can't seem
 to get it to work. I've been following two entries from the wiki (mainly)
 this (http://wiki.mutt.org/?MuttGuide/UseIMAP) and this
 (http://wiki.mutt.org/?UserStory/GmailMultiIMAP), if I purely follow the
 first link, then mutt responds with there being no maildir.
 If I purely follow the second link then it recognizes the maildir, but it
 shows that there are no mailboxes.
 A finesse to this is that my uni mail has a different ending from the imap
 server (the other is a gmail account). Could someone help me point out the
 flaws in my configuration?
 
 # Base hook to reset account variables to known state before activating
 new ones
   account-hook . 'unset preconnect imap_user imap_pass imap_authenticators;
 set ssl_starttls=ask-yes'
 
   account-hook imaps://imap.gmail.com:993/ 'set imap_user=Gmail-user
 imap_pass=Pass'
   folder-hook imaps://imap.gmail.com:993/ 'set
 folder=imaps://imap.gmail.com/INBOX record=+Sent from=My Name
 gmail-u...@gmail.com'
 
   account-hook imaps://uni-imap-server.com/ 'set imap_user=Uni-user
 imap_pass=Pass2'
   folder-hook imaps://uni-imap-server.com/ 'set
 folder=imaps://uni-imap-server.com/INBOX record=+Sent from=My Name
 uni-m...@uni-mail-address.com'
 
 If I add a folder and a spoolfile line (independent of the hooks) then
 this setup works, but would I need to set a spoolfile and a folder for
 both accounts? I think I tried it, but I'm not quite certain.
 
 Any help would be appreciated :-)

Have you tried Offlineimap? I am using it with great success. Read here:

http://miggysmith.wordpress.com/2009/05/02/gmail1/

--
Chuck Smith

 
 
 -- 
 Zeerak


Re: Mutt and multiple imap accounts

2010-02-20 Thread Zeerak Waseem
On Sat, 20 Feb 2010 15:10:18 +0100, Chuck Smith chuck.smit...@gmail.com  
wrote:



On Sat, Feb 20, 2010 at 02:57:41PM +0100, Zeerak Waseem wrote:

Hey,

I'm having some difficulties with mutt and multiple imaps; I've been
trying to set it up for my private mail and my uni mail, but I can't  
seem
to get it to work. I've been following two entries from the wiki  
(mainly)

this (http://wiki.mutt.org/?MuttGuide/UseIMAP) and this
(http://wiki.mutt.org/?UserStory/GmailMultiIMAP), if I purely follow the
first link, then mutt responds with there being no maildir.
If I purely follow the second link then it recognizes the maildir, but  
it

shows that there are no mailboxes.
A finesse to this is that my uni mail has a different ending from the  
imap
server (the other is a gmail account). Could someone help me point out  
the

flaws in my configuration?

# Base hook to reset account variables to known state before activating
new ones
  account-hook . 'unset preconnect imap_user imap_pass  
imap_authenticators;

set ssl_starttls=ask-yes'

  account-hook imaps://imap.gmail.com:993/ 'set imap_user=Gmail-user
imap_pass=Pass'
  folder-hook imaps://imap.gmail.com:993/ 'set
folder=imaps://imap.gmail.com/INBOX record=+Sent from=My Name
gmail-u...@gmail.com'

  account-hook imaps://uni-imap-server.com/ 'set imap_user=Uni-user
imap_pass=Pass2'
  folder-hook imaps://uni-imap-server.com/ 'set
folder=imaps://uni-imap-server.com/INBOX record=+Sent from=My Name
uni-m...@uni-mail-address.com'

If I add a folder and a spoolfile line (independent of the hooks) then
this setup works, but would I need to set a spoolfile and a folder for
both accounts? I think I tried it, but I'm not quite certain.

Any help would be appreciated :-)


Have you tried Offlineimap? I am using it with great success. Read here:

http://miggysmith.wordpress.com/2009/05/02/gmail1/

--
Chuck Smith




--
Zeerak


I'll bear it in mind, but one of the reasons I went with regular imap, is  
that mutt can handle it without any need for other tools. So I'll bear the  
offline imap in mind, but if it's possible to get it working with regular  
imap then that really would be for the best.


--
Zeerak


Re: Multiple IMAP accounts

2008-01-28 Thread Alain Bench
Hello Florian,

 On Sunday, January 27, 2008 at 12:41:52 +0100, Florian Unglaub wrote:

 I set up accounthooks for each account to define spoolfiles, mbox,
 records etc.

You misuse account-hooks; Setup folder-hooks instead.


 checks on new mail in account B won't work until I manually open one
 mailbox in account B.

unset imap_passive


Bye!Alain.
-- 
Everything about locales on Sven Mascheck's excellent site at new
location URL:http://www.in-ulm.de/~mascheck/locale/. The little tester
utility is at URL:http://www.in-ulm.de/~mascheck/locale/checklocale.c.


Multiple IMAP accounts

2008-01-27 Thread Florian Unglaub

Hello,

i'm currently using two imap accounts with mutt (let's call them account
A and account B). I set up accounthooks
for each account to define spoolfiles, mbox, records etc.
Mail is checked in all subscribed folders, but that's exaclty the
problem i have.
During startup mutt connects to account A and lists
correctly all folders I'm subscribed to. New messages for all the
mailboxes in account A are displayed. To see all subscribed folders and
checks on new mail in account B won't work until I manually open one
mailbox in account B.

Is there any better way to have multiple accounts working in mutt?
Something like an automatical connection to account B when starting
mutt?


My mutt version is 1.5.17, relevant parts of my mutt configuration:

##
set imap_authenticators=
set imap_delim_chars=/.
set imap_keepalive=300
unset imap_list_subscribed
set imap_passive
set imap_peek
set imap_servernoise
set mail_check=60
set imap_check_subscribed

# Account A
set spoolfile=imap://localhost:6000/INBOX
set record=imap://localhost:6000/sentmail
set postponed=imap://localhost:6000/postponed
set mbox=imap://localhost:6000/savedmail
set folder=imap://localhost:6000/

account-hook . 'unset folder'
account-hook . 'unset imap_pass'
source ~/.mutt/accounthook_A #spoolfile etc
source ~/.mutt/accounthook_B

#inboxes for Account A and B
mailboxes imaps://imap.gmail.com/INBOX imap://localhost:6000/INBOX
##

Regargs,
F. Unglaub.



Re: Multiple IMAP accounts

2008-01-27 Thread Raffi Khatchadourian

On Sun 27.Jan'08 at 12:41:52 +0100, Florian Unglaub wrote:

Is there any better way to have multiple accounts working in mutt?


Yes, there is! Unfortunately, mutt doesn't handle imap as well as it
handles mbox and maildir. Therefore, I recommend using OfflineIMAP with
mutt.

Raffi


multiple IMAP accounts, sidebar

2007-04-27 Thread Brian S. Lewis
I have several IMAP accounts on the same server, imap://localhost:14300 (SSH 
tunneled). I want to be able to see all the new 
mail in one spot, so I use the sidebar patch.

It seems problematic to use account-hook or folder-hook because all of the 
accounts are on the same host. I set up stuff like
127.0.0.1 m1 m2 m3 m4 m5
in /etc/hosts to facilitate doing stuff like
mailboxes imap://m1:14300/INBOX
account-hook imap://m1:14300/ 'set imap_user=u1 imap_pass=p1'
folder-hook imap://m1:14300 'set spoolfile=imap://m1:14300/INBOX 
folder=imap://m1:14300/'
etc.

If I do that for each account, my sidebar looks like
INBOX
INBOX
INBOX
INBOX
all indistinguishable. Not too useful.

If I leave /INBOX off of the mailboxes directive, I get a more meaningful 
folder name in the sidebar, but I need meaningful 
names for all the various folders. I could hack by creating lots of /etc/hosts 
127.0.0.1 aliases and lots of folder-hooks, but 
sheesh.

It's just seeming ridiculously difficult to do this. Someone, please save me. 
Thanks.


Re: multiple IMAP accounts, sidebar

2007-04-27 Thread Derek Martin
On Fri, Apr 27, 2007 at 05:25:41AM -0500, Brian S. Lewis wrote:
 I have several IMAP accounts on the same server,
 imap://localhost:14300 (SSH tunneled). I want to be able to see all
 the new mail in one spot, so I use the sidebar patch.

Why multiple accounts on the same server?  Hmmm...  That's probably
not a useful question.  

Do you have (at least some) control over the server?  If so, then the
best thing to do is alias the different e-mail addresses all to one
user on the server, and then use procmail to filter mail to different
addresses into different folders.  

That's what I do.  I have multiple domains on the same mail server,
and numerous accounts in each domain, and they are all just aliases to
the same user.  Procmail filters them into various folders, either
based on who they were sent by, or which of my accounts they were
sent to.  You can then use folder hooks to make sure you reply with
the right address...

-- 
Derek D. Martinhttp://www.pizzashack.org/   GPG Key ID: 0xDFBEAD02
-=-=-=-=-
This message is posted from an invalid address.  Replying to it will result in
undeliverable mail.  Sorry for the inconvenience.  Thank the spammers.



pgpNG08YB2GSi.pgp
Description: PGP signature


Re: From: header wrong w/ multiple IMAP accounts

2002-10-01 Thread Michael Tatge

Kurt Lieber ([EMAIL PROTECTED]) muttered:
 I have two accounts on the same IMAP server.  I can successfully navigate
 between accounts using account-hooks. However, in both accounts, the
 From: header defaults to my username followed by the @ sign.  (i.e.
 kurtl@)
 I've set both the $envelope_from and $from variables, but that doesn't
 help. If I set up mutt with just one IMAP account (and no account-hooks),
 it works fine.

To switch between accounts please use my_hdr From:

HTH,

Michael
-- 
I did this 'cause Linux gives me a woody.  It doesn't generate revenue.
(Dave '-ddt-` Taylor, announcing DOOM for Linux)

PGP-Key: http://www-stud.ims.uni-stuttgart.de/~tatgeml/public.key



From: header wrong w/ multiple IMAP accounts

2002-09-30 Thread Kurt Lieber

I'm setting up mutt for the first time and have been able to answer most
of my questions through the docs and list archives.  However, I've hit a
wall on one issue.

I have two accounts on the same IMAP server.  I can successfully navigate
between accounts using account-hooks.  However, in both accounts, the
From: header defaults to my username followed by the @ sign.  (i.e.
kurtl@)

I've set both the $envelope_from and $from variables, but that doesn't
help.  If I set up mutt with just one IMAP account (and no account-hooks),
it works fine.  Here are the relevant portions from my .muttrc.  Any help
is appreciated.  Also, I'm new to mutt, so if I'm doing something the hard
way, please let me know.


account-hook . 'unset imap_pass; unset spoolfile; unset folder; \
unset record; unset postponed; unset from; unset realname; \
unset hostname; unset sort; unset sort_aux'

account-hook imap:[EMAIL PROTECTED]/ \
   'set spoolfile=imap:[EMAIL PROTECTED]/INBOX; \
set folder=imap:[EMAIL PROTECTED]/; \
set record=imap:[EMAIL PROTECTED]/INBOX.Sent; \
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts; \
set use_from; \
set envelope_from; \
set [EMAIL PROTECTED]; \
set hostname=my.server.com'

account-hook imap:[EMAIL PROTECTED]/ \
   'set spoolfile=imap:[EMAIL PROTECTED]/INBOX; \
set folder=imap:[EMAIL PROTECTED]/; \
set record=imap:[EMAIL PROTECTED]/INBOX.Sent; \
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts; \
set use_from; \
set envelope_from; \
set [EMAIL PROTECTED]; \
set hostname=my.server.com'

folder-hook . 'unset sort; unset sort_aux; unset from; unset hostname'

folder-hook imap:[EMAIL PROTECTED]/ 'set sort=threads; set
sort_aux=reverse-date-received'

folder-hook imap:[EMAIL PROTECTED]/ 'set sort=reverse-date-received'


--kurt






Re: my_hdr not working with multiple IMAP accounts

2002-09-30 Thread Michael Herman

On Sun, Sep 29, 2002 at 01:46:28PM -0400, Kurt Lieber wrote:
I'm setting up mutt for the first time.  I have two separate accounts,
both on the same IMAP server -- I want to set default From: addresses for
each of those accounts.  My first question is; do I use account-hook or
folder-hook?

I use folder-hook as my sending is generally related to what I'm
reading or doing.


My next question; I've tried it using both, and while I can *check* mail
just fine, the From header is not displayed correctly in either account. 
My relevant portions of .muttrc:

#set some default locations
set spoolfile=imap:[EMAIL PROTECTED]/INBOX
set folder=imap:[EMAIL PROTECTED]/
set record=imap:[EMAIL PROTECTED]/INBOX.Sent
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts
my_hdr From: Kurt Lieber [EMAIL PROTECTED]


Try 'set from=[EMAIL PROTECTED]'


account-hook . 'unset spoolfile folder record postponed hostname
pgp_autosign; unmy_hdr From:'

account-hook imap:[EMAIL PROTECTED]/ \
   'set spoolfile=imap:[EMAIL PROTECTED]/INBOX; \
set folder=imap:[EMAIL PROTECTED]/; \
set record=imap:[EMAIL PROTECTED]/INBOX.Sent; \
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts; \
my_hdr From: Kurt Lieber [EMAIL PROTECTED]; \

same thing here- 'set from=[EMAIL PROTECTED]'



HTH.

-- 
Michael Herman



msg31320/pgp0.pgp
Description: PGP signature


my_hdr not working with multiple IMAP accounts

2002-09-29 Thread Kurt Lieber

I'm setting up mutt for the first time.  I have two separate accounts,
both on the same IMAP server -- I want to set default From: addresses for
each of those accounts.  My first question is; do I use account-hook or
folder-hook?

My next question; I've tried it using both, and while I can *check* mail
just fine, the From header is not displayed correctly in either account. 
My relevant portions of .muttrc:

#set some default locations
set spoolfile=imap:[EMAIL PROTECTED]/INBOX
set folder=imap:[EMAIL PROTECTED]/
set record=imap:[EMAIL PROTECTED]/INBOX.Sent
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts
my_hdr From: Kurt Lieber [EMAIL PROTECTED]

account-hook . 'unset spoolfile folder record postponed hostname
pgp_autosign; unmy_hdr From:'

account-hook imap:[EMAIL PROTECTED]/ \
   'set spoolfile=imap:[EMAIL PROTECTED]/INBOX; \
set folder=imap:[EMAIL PROTECTED]/; \
set record=imap:[EMAIL PROTECTED]/INBOX.Sent; \
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts; \
my_hdr From: Kurt Lieber [EMAIL PROTECTED]; \
set hostname=merau.pair.com'

account-hook imap:[EMAIL PROTECTED]/ \
   'set spoolfile=imap:[EMAIL PROTECTED]/INBOX; \
set folder=imap:[EMAIL PROTECTED]/; \
set record=imap:[EMAIL PROTECTED]/INBOX.Sent; \
set postponed=imap:[EMAIL PROTECTED]/INBOX.Drafts; \
my_hdr From: Kurt Lieber [EMAIL PROTECTED]; \
set hostname=myserver.com; \
set pgp_autosign'

If I replace all occurances of account-hook with folder-hook, it still
doesn't work.  I'm pretty sure I'm using 'unmy_hdr' wrong, but I'm not
sure where.

I've also tried using $use_from and $from, but I couldn't get that to
work, either.

What I'm trying to accomplish is simply the following:  If I'm in my lists
mail account, set the From address to [EMAIL PROTECTED]  If I change to
my main account, set the From address to [EMAIL PROTECTED]

Any help is appreciated.

--kurt






Re: my_hdr not working with multiple IMAP accounts

2002-09-29 Thread Sven Guckes

* Kurt Lieber [EMAIL PROTECTED] [2002-09-29 17:48]:
 I'm setting up mutt for the first time.[..]
 Any help is appreciated.

since you have also posted this to comp.mail.mutt
i suggest that you look for answer on that medium.

Sven



Re: my_hdr not working with multiple IMAP accounts

2002-09-29 Thread Kurt Lieber

On Mon, Sep 30, 2002 at 12:42:49AM +0200 or thereabouts, Sven Guckes wrote:
 since you have also posted this to comp.mail.mutt
 i suggest that you look for answer on that medium.

Actually, my post to comp.mail.mutt was Round 1.  My post to the list was
Round 2.  Round 1, I was using $from.  Based on a suggestion from someone
else, I switched to using $my_hdr instead, and I still ran into problems.

If you have already replied to comp.mail.mutt, my news server hasn't
received the post yet.

As for the issue at hand, I've found a work-around by placing each account
personality in its own file and sourcing that separately.  Combining that
with some macros seems to have solved the problem.  For anyone else who
runs into this problem, a great resource is:

http://www.acoustics.hut.fi/~mara/mutt/profiles.html

I'm still curious if there's a way to get the same functionality using
hooks, if only from an academic standpoint.

Thanks.

--kurt



Managing multiple IMAP accounts

2002-05-30 Thread jennyw

I'm having trouble trying to access two IMAP accounts on the same server. 
I'm trying to do it using account-hook.

my .muttrc looks like:

set record=imap://jennyw@localhost/INBOX.Sent
set imap_pass=password
set spoolfile=imap://jennyw@localhost/INBOX
set folder=imap://jennyw@localhost/
account-hook imap://jennyw2@localhost 'set imap_pass=password2'

I also tried adding:

account-hook . 'unset imap_pass'

since it was in the manual, even though I'm not really sure when it's 
invoked (I figured it was used as an example because it referred to the 
local Maildir?).

Anyway, thanks in advance!

Jen



Another problem with multiple IMAP accounts

2000-08-16 Thread cgreen

I have just encountered another problem when using multiple IMAP
accounts - how do I set the $imap_user and $imap_pass to different
values for each IMAP server?

When moving messages around I want to be able to stay logged in to
more than one IMAP account at the same time.

-- 
Chris Green ([EMAIL PROTECTED])
  Home: [EMAIL PROTECTED]   Work: [EMAIL PROTECTED]
  WWW: http://www.isbd.co.uk/




Re: Another problem with multiple IMAP accounts

2000-08-16 Thread Brendan Cully

On Wednesday, 16 August 2000 at 06:31, [EMAIL PROTECTED] wrote:
 I have just encountered another problem when using multiple IMAP
 accounts - how do I set the $imap_user and $imap_pass to different
 values for each IMAP server?

For imap_user, you can embed the username in the account, as in
{user@host}. There is no solution for imap_pass. But once you've
connected, the account information for each account is cached. So you
can log in to one account, set imap_pass to the password for your next
account, and connect to it. Once the connections are established you
should be fine. You may wish to write some "profile" macros to do some
of this for you.

I'm interested in writing some sort of account-hook code later to
handle changing these sorts of parameters when you use another
account. But for now, this will have to do...

-- 
Don't make Godzilla mad!

 PGP signature


Re: Another problem with multiple IMAP accounts

2000-08-16 Thread cgreen

On Wed, Aug 16, 2000 at 08:00:32AM -0400, Brendan Cully wrote:
 On Wednesday, 16 August 2000 at 06:31, [EMAIL PROTECTED] wrote:
  I have just encountered another problem when using multiple IMAP
  accounts - how do I set the $imap_user and $imap_pass to different
  values for each IMAP server?
 
 For imap_user, you can embed the username in the account, as in
 {user@host}. There is no solution for imap_pass. But once you've
 connected, the account information for each account is cached. So you
 can log in to one account, set imap_pass to the password for your next
 account, and connect to it. Once the connections are established you
 should be fine. You may wish to write some "profile" macros to do some
 of this for you.
 
OK, thanks, this makes it quite usable.


 I'm interested in writing some sort of account-hook code later to
 handle changing these sorts of parameters when you use another
 account. But for now, this will have to do...
 
That would be nice, but I must admit this is just an occasional
requirement when I've decided to do a big re-arrangement for some
reason or another.

-- 
Chris Green ([EMAIL PROTECTED])
  Home: [EMAIL PROTECTED]   Work: [EMAIL PROTECTED]
  WWW: http://www.isbd.co.uk/




Re: Multiple IMAP accounts?

2000-03-26 Thread Charles Curley

On Sat, Mar 25, 2000 at 06:14:43PM -0600, Ben Beuchler muttered:
- Has anyone come up with a way to access multiple IMAP accounts on
- different servers from mutt?  Or even a way to configure a macro that will
- switch me from one to the other?
- 
- Or am I stuck setting up two seperate .muttrc files and restarting mutt to
- switch?

Fetchmail.

-- 

-- C^2

No windows were crashed in the making of this email.

Looking for fine software and/or web pages?
http://w3.trib.com/~ccurley



Multiple IMAP accounts?

2000-03-25 Thread Ben Beuchler

Has anyone come up with a way to access multiple IMAP accounts on
different servers from mutt?  Or even a way to configure a macro that will
switch me from one to the other?

Or am I stuck setting up two seperate .muttrc files and restarting mutt to
switch?

Gracias,
Ben

-- 
"There is no spoon"
-- The Matrix



Re: Multiple IMAP accounts?

2000-03-25 Thread Tommi Komulainen

On Sat, Mar 25, 2000 at 06:14:43PM -0600, Ben Beuchler wrote:
 Has anyone come up with a way to access multiple IMAP accounts on
 different servers from mutt?  Or even a way to configure a macro that
 will switch me from one to the other?

Been there, done that, forgot the documentation :-]

mailbox {[EMAIL PROTECTED]}

Works even with multiple accounts on the same server.


-- 
Tommi Komulainen   [EMAIL PROTECTED]