ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/repos/FreeBSDAdmin/Mail/SetupMail.sh
Revision: 827
Committed: 2006-07-06T01:41:14-07:00 (18 years, 11 months ago) by douglas
Content type: text/x-sh
File size: 784 byte(s)
Log Message:
SpamD!

File Contents

# User Rev Content
1 douglas 809 #!/usr/local/bin/bash
2     # Setup Mail
3     #
4     # Douglas Thrift
5     #
6     # $Id$
7    
8 douglas 827 user="`whoami`"
9    
10 douglas 809 for mailbox in INBOX Sent\ Items Drafts Spam/{Assassin,False\ {Negative,Positive}}; do
11 douglas 810 mkdir -pv -m 0700 ~/.imap_mail
12     if [[ ! -f "$HOME/.imap_mail/$mailbox" ]]; then
13     echo -n "Creating $mailbox..."
14     mailutil create -verbose "$mailbox"
15     echo "done."
16 douglas 809 fi
17     done
18    
19 douglas 811 mkdir -pv ~/bin
20    
21 douglas 827 if [[ "$user" == "douglas" ]]; then
22 douglas 818 install -pv SpamUpdate ~/bin/SpamUpdate
23 douglas 809 else
24     ln -fsv ~douglas/bin/SpamUpdate ~/bin/SpamUpdate
25     fi
26 douglas 827
27     forward="dot.forward.$user"
28    
29     sed -e "s/%%user%%/$user/" dot.forward > "$forward"
30     install -pv "$forward" ~/.forward
31     rm -f "$forward"
32    
33     procmailrc="dot.procmailrc.$user"
34    
35     sed -e "s/%%user%%/$user/" dot.procmailrc > "$procmailrc"
36     install -pv "$procmailrc" ~/.procmailrc
37     rm -f "$procmailrc"

Properties

Name Value
svn:executable *
svn:keywords Id