Difference between revisions of "Package:Mutt"

(~/.mutt/sidebar)
(~/.secret/.passwd.gpg)
Line 362: Line 362:
 
* Step 1:
 
* Step 1:
 
Create a folder <tt>~/.secret</tt> and inside a file <tt>.passwd</tt> and enter the following into it:
 
Create a folder <tt>~/.secret</tt> and inside a file <tt>.passwd</tt> and enter the following into it:
<pre>
+
{{File
 +
|~/.secret/.passwd|<pre>
 
user1:    passwd1
 
user1:    passwd1
 
user2:    passwd2
 
user2:    passwd2
</pre>
+
</pre>}}
 
where user1 and user2 are your identifiers for the accounts you added in account_hooks and folder_hooks and at the start of muttrc.
 
where user1 and user2 are your identifiers for the accounts you added in account_hooks and folder_hooks and at the start of muttrc.
 
* Step 2:
 
* Step 2:

Revision as of 21:49, 26 January 2014

Mutt is a popular mail reader for Linux systems. This page is being created as a good place for people to place their mutt configurations to share with others. These configuration settings go in the user's ~/.muttrc file.

Essential Mutt

set pager_stop

This turns off the default behavior of mutt where hitting space to scroll will automatically move to the next message when the end of the current message is reached. This is very annoying when scrolling in long emails like cron jobs, and the line above sets this behavior to off.

angry_vincent's .muttrc:

{{{name}}}
{{{body}}}

Interesting Color Options

http://github.com/altercation/mutt-colors-solarized

golodhrim's mutt config

First I split up my muttconfig in several subfiles under ~/.mutt. The resulting files will be:

  • ~/.mutt/account_hooks
  • ~/.mutt/colors
  • ~/.mutt/folder_hooks
  • ~/.mutt/gpg
  • ~/.mutt/lists
  • ~/.mutt/macros
  • ~/.mutt/mutt-alias
  • ~/.mutt/muttrc
  • ~/.mutt/sidebar
  • ~/.secret/.passwd.gpg

account_hooks

Next, edit ~/.mutt/account_hooks</pre>:

{{{name}}}
{{{body}}}

colors

{{{name}}}
{{{body}}}

folder_hooks

{{{name}}}
{{{body}}}

~/.mutt/gpg

{{{name}}}
{{{body}}}

~/.mutt/lists

{{{name}}}
{{{body}}}

~/.mutt/macros

{{{name}}}
{{{body}}}

~/.mutt/alias

{{{name}}}
{{{body}}}

~/.mutt/muttrc

{{{name}}}
{{{body}}}

~/.mutt/sidebar

{{{name}}}
{{{body}}}

~/.secret/.passwd.gpg

For this file follow the next steps:

  • Step 1:

Create a folder ~/.secret and inside a file .passwd and enter the following into it:

{{{name}}}
{{{body}}}

where user1 and user2 are your identifiers for the accounts you added in account_hooks and folder_hooks and at the start of muttrc.

  • Step 2:

Now encrypt the file with your gpg-key, if you don't have one execute gpg --gen-key and create one first. After that don't forget to delete your unencrypted passwordstorage.

$ gpg -r 0x<Your-ID-fingerprint> -o .passwd.gpg --encrypt .passwd
$ rm -f .passwd

Mutt postfix setup

Postfix is another popular and powerful mail transfer agent which somehow easier to configure than sendmail. Let's start a quick postfix mail transfer setup that will work with mutt. Set sasl,berkdb USE flags to mail-mta/potsfix and mail-client/mutt

# echo "mail-mta/postfix berkdb sasl" >> /etc/portage/package.use/mail
# echo "mail-client/mutt berkdb sasl" >> /etc/portage/package.use/mail
# emerge -uN1 mutt postfix

Edit /etc/postfix/main.cf and add the following lines:

{{{name}}}
{{{body}}}

Create and edit above mentioned authorization file gmail_passwd

# touch /etc/postfix/gmail_passwd
# echo "smtp.gmail.com:587 my.name@gmail.com:password" >> /etc/postfix/gmail_passwd

Where <my.name> is gmail account and passwd is account password. Convert gmail_passwd into Berkeley DB format, secure the file and finaly restart the postfix daemon

# postmap /etc/postfix/gmail_passwd
# chown root:postfix /etc/postfix/gmail_passwd*
# chmod 0640 /etc/postfix/gmail_passwd*
# /etc/init.d/postfix restart