Introduction
Dicemail is a Perl library for working with email messages. The idea of Dicemail is to provide a set of utilities for writing small, simple mail tools. Dicemail provides the following abilties:
- Handling of account specifications
- Abstracts operations on different mail server types (currently only IMAP though)
- Abstracts messages
- Command line switch processing
- Supports operations on mail defined by Perl code
Always happy to receive feedback.
Install
Existing users should read the changelog.
Debian
Gonéri Le Bouder has put together a Debian package. I understand that if you add the line below to your /etc/apt/sources.list file you can use apt-get install libmail-dice-perl and apt-get update:
Source
Pre-requisites
Along with Perl, you will need the following Perl modules:
- Time::TimeDate (1.16)
- Digest::MD5 (2.30)
- Mail::IMAPClient (2.2.9)
- Term::ReadKey (2.21) - optional, but recommended
Version numbers are the minimums, you should be OK with later versions. Your *nix distribution probably has these modules as installable packages.
Build
- Grab Mail-Dice-0.02.tar.gz
- Unpack
- perl Makefile.PL
- make
- make install
Using
The full instructions are in the man pages: Dice::Mail, Dice::Mail::IMAP and Dice::Mail::Message. I recommend you read them to really understand what's going on.
By way of a quick-start:
- Create the directory .dicemail under your home directory.
- Create the directory .dicemail/account. Within this folder create a file named default with details of a mail account. See the examples to get you started.
- Create the directory .dicemail/filter
- Within the filter directory add a suitable base filter with the name base and other filters to taste.
- Fire up a client such as Sickle, don't forget to run in test mode first.
Examples
Accounts
| Name | Description |
|---|---|
| IMAP | IMAP server account. |
Account files must be readable only by the owner for Dicemail to accept them.
Filters
If you've done something interesting with filters, why not contribute them to the greater good?
