Mutt configuration for multiple users

This commit is contained in:
Bob Mottram 2015-10-25 12:29:51 +00:00
parent 70886e08e8
commit 03917ed58e
1 changed files with 5 additions and 2 deletions

View File

@ -6230,6 +6230,7 @@ function configure_email {
addgroup Debian-exim sasl addgroup Debian-exim sasl
/etc/init.d/exim4 restart /etc/init.d/exim4 restart
if [ ! -d /etc/skel/Maildir ]; then if [ ! -d /etc/skel/Maildir ]; then
mkdir -m 700 /etc/skel/.mutt
mkdir -m 700 /etc/skel/Maildir mkdir -m 700 /etc/skel/Maildir
mkdir -m 700 /etc/skel/Maildir/Sent mkdir -m 700 /etc/skel/Maildir/Sent
mkdir -m 700 /etc/skel/Maildir/Sent/tmp mkdir -m 700 /etc/skel/Maildir/Sent/tmp
@ -6248,6 +6249,7 @@ function configure_email {
fi fi
if [ ! -d /home/$MY_USERNAME/Maildir ]; then if [ ! -d /home/$MY_USERNAME/Maildir ]; then
mkdir -m 700 /home/$MY_USERNAME/.mutt
mkdir -m 700 /home/$MY_USERNAME/Maildir mkdir -m 700 /home/$MY_USERNAME/Maildir
mkdir -m 700 /home/$MY_USERNAME/Maildir/cur mkdir -m 700 /home/$MY_USERNAME/Maildir/cur
mkdir -m 700 /home/$MY_USERNAME/Maildir/tmp mkdir -m 700 /home/$MY_USERNAME/Maildir/tmp
@ -7030,8 +7032,9 @@ function email_client {
mkdir /home/$MY_USERNAME/.mutt mkdir /home/$MY_USERNAME/.mutt
fi fi
echo "text/html; lynx -dump -width=78 -nolist %s | sed s/^ //; copiousoutput; needsterminal; nametemplate=%s.html" > /home/$MY_USERNAME/.mutt/mailcap echo "text/html; lynx -dump -width=78 -nolist %s | sed s/^ //; copiousoutput; needsterminal; nametemplate=%s.html" > /home/$MY_USERNAME/.mutt/mailcap
cp /home/$MY_USERNAME/.mutt/mailcap /etc/skel/.mutt
chown -R $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.mutt chown -R $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.mutt
chown -R root:root /etc/skel/.mutt
echo 'set mbox_type=Maildir' >> /etc/Muttrc echo 'set mbox_type=Maildir' >> /etc/Muttrc
echo 'set folder="~/Maildir"' >> /etc/Muttrc echo 'set folder="~/Maildir"' >> /etc/Muttrc
@ -7142,9 +7145,9 @@ function email_client {
fi fi
cp -f /etc/Muttrc /home/$MY_USERNAME/.muttrc cp -f /etc/Muttrc /home/$MY_USERNAME/.muttrc
cp -f /etc/Muttrc /etc/skel/.muttrc
touch /home/$MY_USERNAME/.mutt-alias touch /home/$MY_USERNAME/.mutt-alias
chown $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.emacs-mutt chown $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.emacs-mutt
cp /home/$MY_USERNAME/.emacs-mutt /etc/skel
chown $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.muttrc chown $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.muttrc
chown $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.mutt-alias chown $MY_USERNAME:$MY_USERNAME /home/$MY_USERNAME/.mutt-alias