You are not logged in.
Hi all,
actually on my mutt i'm using 3 imaps account, which i change by 3 folder hooks
macro index \e1 "c imaps://account1"
macro index \e2 "c imaps://account2"
macro index \e3 "c imaps://account3"
every hook is configured like this
account-hook imaps://address1:port1 'set imap_user=user1 imap_pass=pass1'
folder-hook imaps://address1:port1 'set folder=imaps://address1:port1/INBOX record=+Sent from="Real Name <mail1@provider1.asd>"; \
set smtp_url="smtps://smtp1:portsmtp1"; \
set smtp_pass="pass1"'
where, obviously, account, user etc are the real data
having mutt configured like this, i cannot have every account's folder on the sidebar, since they are different an all on different servers. is it possibile to change folder displayed with the sidebar automatically within the hooks?
and last question: is it possible to setu a default hook, to be opened every time mutt starts?
thanks all!
Last edited by samuele.mattiuzzo (2010-08-22 17:50:45)
Offline
Use 'mailboxes' to add folders to the sidebar and 'unmailboxes' to remove folders.
I would store your account data in different files and source them when needed:
macro index \e1 "source /path/to/account1.muttrc"
macro index \e2 "source /path/to/account2.muttrc"
macro index \e3 "source /path/to/account2.muttrc"
Each account#.muttrc file would have something like this in it:
set imap_user=user1
set imap_pass=pass1
set folder=imaps://address1:port1/
set record=+Sent
set from="Real Name <mail1@provider1.asd>"
set smtp_url="smtps://smtp1:portsmtp1"
set smtp_pass="pass1"
unmailboxes *
mailboxes =INBOX =Drafts =Sent =Trash
Your main ~/.muttrc would source one of these files in start (e.g. 'source /path/to/account1.muttrc').
Last edited by Stebalien (2010-08-22 17:45:51)
Steven [ web : git ]
GPG: 327B 20CE 21EA 68CF A7748675 7C92 3221 5899 410C
Do not email: honeypot@stebalien.com
Offline
thanks, now my muttrc is cleaner and it does the same thing as before! thanks a lot!
Offline
sorry to bump this thread up again, but i'm having a big problem
when i press esc-1 it doesn't source another account.muttrc file, but ask me to save into "ource~/.mutt/account.muttrc"
59 set header_cache=~/.mutt/cache/headers
60 set message_cachedir=~/.mutt/cache/bodies
61 set certificate_file=~/.mutt/certificates
62 set spoolfile = no
63
64 source ~/.mutt/dsi.muttrc
65
66 macro index \e1 "source ~/.mutt/samumatt.muttrc"
67
68 macro index \e2 "source ~/.mutt/vivosunamela85.muttrc"
69
70 macro index \e3 "source ~/.mutt/dsi.muttrc"
71
72 macro index \e4 "source ~/.mutt/archus.muttrc"
what's wrong? (the default sourcing works, not the macros)
Last edited by samuele.mattiuzzo (2010-08-30 16:25:47)
Offline
What happens if you change the lines to:
macro index \e1 ":source ...
Offline
it works, halfly... it sources the file, but doesn't change the inbox (so i still see the one before)
Offline
I misunderstood what you were after: see my .muttrc for the keybinds I use to move between folders
Offline