Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 11 Oct 2000 13:14:17 -0500
From:      Isetr0 Savi <isetr0@sevicron.com>
To:        Jie Liang <jliang@ipinc.com>
Cc:        questions@FreeBSD.org
Subject:   Re: FreeBSD mail
Message-ID:  <20001011131417.A199@sevicron.com>
In-Reply-To: <39E49E1C.CE2C4FAB@ipinc.com>; from jliang@ipinc.com on Wed, Oct 11, 2000 at 10:06:36AM -0700
References:  <39E49E1C.CE2C4FAB@ipinc.com>

next in thread | previous in thread | raw e-mail | index | archive | help
See answer below...
	
On Wed, Oct 11, 2000 at 10:06:36AM -0700, Jie Liang wrote:
> Hi,
> 
> I have a script which takes STDIN and parses mail into my database,
> I want to know how to use a email address to fire my script when a new
> mail recieved.
> say my email is jliang@ipinc.com
> 
> I'd like to fire my script say myscript when I recieved a mail.
> 
## Left this in for useful info - real solution below :)
# Take a look at maildrop or procmail.  Both are in /usr/ports/mail/ if
# you have the ports installed.  I prefer maildrop, but it's up to you -
# either one should do the trick, I believe...
##

Actually....you can just put this in your ~/.forward file
"|exec /bin/myscript"

I'm not sure that the syntax is correct ( i.e. don't know if you need
the exec or not) but that pipes your mail into whatever program you
specify. And you can always read man forward too :)

Good luck!

isetr0


To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20001011131417.A199>