1# define the database for duplicates, use the message-id header for it and keep the database for 1 month; fdm needs to be built with 'make DB=1' to use this 2$db = "~/.fdm.duplicate-db" 3$key = "%[message_id]" 4cache $db expire 1 month 5 6# a reasonable timeout for my pop3s server 7set timeout 60 8 9# my maildirs � la pine, with action, month and two digits year tags 10action 'received' maildir "%h/.maildir/%t-%m-%[year2]" 11action 'banca' maildir "%h/.maildir/%t-%m-%[year2]" 12action 'crux' maildir "%h/.maildir/%t-%m-%[year2]" 13action 'tuxonice' maildir "%h/.maildir/%t-%m-%[year2]" 14action 'dwm' maildir "%h/.maildir/%t-%m-%[year2]" 15action 'vimperator' maildir "%h/.maildir/%t-%m-%[year2]" 16action 'filosofia' maildir "%h/.maildir/%t-%m-%[year2]" 17action 'sent' maildir "%h/.maildir/%t-%m-%[year2]" 18action 'osml' maildir "%h/.maildir/%t-%m-%[year2]" 19# a general maildir for cron jobs 20action 'cron' maildir "%h/.maildir/%t" 21# a sound for all my mails 22action 'sound' exec "/usr/bin/aplay -q ~/.xchat2/sounds/bong.au" 23# esmtp, my very simple MTA, is able to deliver local mail from cron jobs and so, but does not add Date: and From: headers 24action 'esmtpdate' add-header "From" "%u@%[hostname]" 25action 'esmtpfrom' add-header "Date" "%[rfc822date]" 26# the maildir for duplicates, since some false duplicates can be detected when a previous instance of fdm gets interrupted 27action 'duplicates' maildir "%h/.maildir/%t" 28# the standard drop and keep actions 29action 'null' drop 30action 'one' keep 31 32# my gmail account 33account 'gmail' pop3s server "pop.gmail.com" port 995 user "x" pass "y" 34# the standard input account 35account 'stdin' disabled stdin 36 37# first of all, the sound 38match all action "sound" continue 39# add the missing headers for local mail 40match account "stdin" action 'esmtpdate' continue 41match account "stdin" action 'esmtpfrom' continue 42# cron jobs 43match account "stdin" and "^(From).*(root|patroclo7|mvpozzato)" in headers and "^(Subject).*(cron)" in headers action "cron" 44# local mail does not need to be filtered any further 45match account "stdin" action "received" 46# catch duplicates 47match not string $key to "" { 48 match in-cache $db key $key action "duplicates" 49 } 50# update the duplicates db 51match all action to-cache $db key $key continue 52# drop 53match "^(From).*(postmaster\@postmaster\.libero\.it)" in headers action "null" 54# the mails I have sent from gmail web interface 55match "^(From).*(patroclo7\@gmail.com)" in headers action "sent" 56# philosophy mailing lists; stuff about jobs needs to be also in the default maildir 57match "^(To|List-Id).*(liverpool|swif|sequitur)" in headers { 58 match "^(Subject).*(job)" in headers action "received" continue 59 match all action "filosofia" 60 } 61# bank stuff 62match "^(From).*(iwbank)" in headers action "banca" 63# stuff from OS mailing lists and forums 64match "^(To|List-Id).*(crux)" in headers action "crux" 65match "^(To|List-Id).*(vimperator)" in headers action "vimperator" 66match "^(To|List-Id).*(dwm).*(suckless)" in headers action "dwm" 67match "^(To|List-Id).*(suspend2|tuxonice)" in headers action "tuxonice" 68match "^(To|List-Id).*(archlinux|crealabs|fdm-users|fish-users|metalog-users|conkeror|ratpoison|muttprint|screen-users|suspend2|rxvt-unicode)" in headers or "^(Return-Path).*(crealabs|pharsc2|archlinux)" in headers action "osml" 69 70# the default destination 71match all action "received" 72 73