auto file email

JQ Johnson jqj at darkwing.uoregon.edu
Mon Sep 14 15:53:28 EDT 1998


Christopher Adams asked about techniques for generating automatic email
replies.

Adams adds:
>I realize that I can easily set an automatic
>vacation message to reply with whatever text I want,
>but the file would be a rather large one and some email
>programs couldn't handle that as an auto vacation reply.

It wasn't quite clear to me what the problem with a "vacation" message
is.  Most vacation programs that I'm familiar with can be used to
produce quite large messages, including messages with attachments.  For
example, the Unix "vacation" program can generate an arbitrarily large
reply (stored in the .vacation.msg template).  The big limitation of
Unix vacation is that by itself it can't do much computation:  you can't
use it to generate different reply messages based on the sender.

Automatic file sending is available with most modern email systems. But
the details differ widely.  For example, most modern MUAs have a
facility for generating an automatic reply based on sender.  In Eudora
Pro you can generate a filter that checks the sender and if it matches
replies with a message, that might include an attachment.  You can do
the same thing with Microsoft Outlook.

On the MTA side, many PC MTAs (e.g. Exchange) include substantial
filtering capabilities.  Bare Unix sendmail does not, but most people
running sendmail also run procmail, which provides excellent (though
hard to use) filtering and reply tools.

A very common setup is a Unix mailbox system with sendmail as MTA and
procmail for filtering.  Many people who install procmail also install
the mh suite, which includes some additional mail composition programs
like formail.  Another useful set of tools is the Borenstein "metamail"
package.  In such an environment you might create a procmail rule
(normally in a file .procmailrc) such as:

	:0 c
	* ^From.*chris at opac.osl.state.or.us
	* !FROM_DAEMON
	* !X-Loop:
	| (formail -r -A"X-Loop: your at own.mail.address" ; \
          cat bigfileforchris) | $SENDMAIL -t

Given the right tools, you can even generate a reply that includes a
non-text attachment, though that requires a bit more knowledge of MIME
formats; if you want to generate non-text attachments, you may be better
off doing it in your graphical MUA. (can anyone give me a good procmail
recipe for an autoreply that generates a MIME multipart, perhaps using
formail and metasend?)

For more help with procmail, see the "procmailex" Unix man page.

JQ Johnson                      Office: 115F Knight Library
Academic Education Coordinator  mailto:jqj at darkwing.uoregon.edu
1299 University of Oregon       phone: 1-541-346-1746; -3485 fax
Eugene, OR  97403-1299          http://darkwing.uoregon.edu/~jqj/



More information about the Web4lib mailing list