Browse Source

Make possible to use mutt with local Maildirs and by IMAP

Emmanuel Bouthenot 14 years ago
parent
commit
e985134d84
3 changed files with 44 additions and 18 deletions
  1. 23 0
      .mutt/accounts/imap
  2. 19 0
      .mutt/accounts/local
  3. 2 18
      .mutt/muttrc

+ 23 - 0
.mutt/accounts/imap

@@ -0,0 +1,23 @@
+# -*- muttrc -*-
+#
+# Mutt configuration file
+# 2006,  kolter <kolter@openics.org>
+#
+#  This file is distributed in the hope that it will be useful,
+#  but WITHOUT ANY WARRANTY
+#
+
+# Dummy header to force generation of ~/.mutt/conf/mailboxes-imap from
+# ~/.mutt/conf/mailboxes
+my_hdr Dummy: `sed 's# +\.# =#' < ~/.mutt/conf/mailboxes > ~/.mutt/conf/mailboxes-imap`
+
+set mail_check      = 60
+
+set folder          = "imap://mx0.openics.org/"
+set mbox            = "imap://mx0.openics.org/INBOX"
+set spoolfile       = "imap://mx0.openics.org/INBOX"
+set record          = "imap://mx0.openics.org/Sent"     # where to save sent mails
+set postponed       = "imap://mx0.openics.org/Draft"    # where to save drafts
+
+source              ~/.mutt/conf/mailboxes-imap
+

+ 19 - 0
.mutt/accounts/local

@@ -0,0 +1,19 @@
+# -*- muttrc -*-
+#
+# Mutt configuration file
+# 2006,  kolter <kolter@openics.org>
+#
+#  This file is distributed in the hope that it will be useful,
+#  but WITHOUT ANY WARRANTY
+#
+
+set mbox_type        = Maildir
+set folder           = "~/Mail/Mailbox"
+set mask             = "^\\.[^.]"
+set mbox             = "~/Mail/Mailbox"
+set record           = "+.Sent"
+set postponed        = "+.Drafts"
+set spoolfile        = "~/Mail/Mailbox"
+
+source              ~/.mutt/conf/mailboxes
+

+ 2 - 18
.mutt/muttrc

@@ -14,27 +14,13 @@ set from            = "kolter@openics.org"
 set signature       = "~/.signatures/main"
 alternates          "kolter|emmanuel\.bouthenot|openics\.org|netconfig|bouthenot\.name"
 
-set envelope_from   = yes                         # set return-path to from instead of user@hostname
+set envelope_from   = yes                       # set return-path to from instead of user@hostname
 set hostname        = openics.org
 
 set locale          = "fr_FR.UTF-8"
 set charset         = "utf-8"
 
-#set folder          = "imap://127.0.0.1"
-#set mbox            = "imap://127.0.0.1/INBOX"
-#set spoolfile       = "imap://127.0.0.1/INBOX"
-#set record          = "imap://127.0.0.1/Sent"     # where to save sent mails
-#set postponed       = "imap://127.0.0.1/Draft"    # where to save drafts
-
-#source              ~/.muttrc-imapauth          # get authentication params for imap
-
-set mbox_type        = Maildir
-set folder           = "~/Mail/Mailbox"
-set mask             = "^\\.[^.]"
-set mbox             = "~/Mail/Mailbox"
-set record           = "+.Sent"
-set postponed        = "+.Drafts"
-set spoolfile        = "~/Mail/Mailbox"
+source              ~/.mutt/accounts/default    # where are my mails ?
 
 set header_cache    = ~/.mutt/cache
 set tmpdir          = ~/.mutt/tmp
@@ -81,8 +67,6 @@ set sort             = reverse-threads
 #set sort            = threads                     # Sort by threads
 #set sort_aux        = reverse-date                # Then sort by date
 
-source              ~/.mutt/conf/mailboxes
-
 source              ~/.mutt/conf/headers           # Configure header display.
 source              ~/.mutt/conf/my-headers        # Set personnal headers.
 source              ~/.mutt/conf/colors            # Define colours.