procmail
[Top] [All Lists]

Re: Executing a program on reception of mail from someone

1998-01-12 19:59:53
On Mon, 12 Jan 1998, Peter S Galbraith wrote:

I'm trying to play a particular sound file when I get mail from
a particular person.

This rule does not work:

:0 c
* ^From: Peter S Galbraith <galbraith(_at_)mixing(_dot_)qc(_dot_)dfo(_dot_)ca>
| /usr/X11R6/bin/auplay /usr/lib/exmh/drip.au

However, this rule does redirect a copy of mail from me correctly:

:0 c
* ^From: Peter S Galbraith <galbraith(_at_)mixing(_dot_)qc(_dot_)dfo(_dot_)ca>
testfile

And this command in a shell does procude a sound:

cat anyfile | /usr/X11R6/bin/auplay /usr/lib/exmh/drip.au

Any hints?

Maybe the "auplay" command, in order to work, needs to be attached to a
console. I'm guessing that the fact that auplay is being spawned by
procmail means that it isn't attached.

This is just a wild guess, (and I wouldn't know how to attach it to a
console if this theory is correct). 

You could also check your auplay man page and see if you can force it to
play on your audio device by using some additional parameters on the
command line.

-- kurt


<Prev in Thread] Current Thread [Next in Thread>