Subject: Re: mailing notifications automatically
To: Tony Hernadez <tony@cne-inc.com>
From: Manuel Bouyer <bouyer@antioche.lip6.fr>
List: tech-security
Date: 09/06/2000 16:25:48
  by mail.netbsd.org with SMTP; 6 Sep 2000 14:25:50 -0000
	by antioche.lip6.fr (8.10.1/8.10.1) with ESMTP id e86EPnv13259;
	Wed, 6 Sep 2000 16:25:49 +0200 (MEST)
Date: Wed, 6 Sep 2000 16:25:48 +0200
From: Manuel Bouyer <bouyer@antioche.lip6.fr>
To: Tony Hernadez <tony@cne-inc.com>
Cc: "'tech-security@netbsd.org'" <tech-security@netbsd.org>
Subject: Re: mailing notifications automatically
Message-ID: <20000906162548.A21286@antioche.lip6.fr>
References: <E10D54F27C6AD11196EF00600812C5CF067E9D@CNENT>
Mime-Version: 1.0
Content-Type: text/plain; charset=us-ascii
In-Reply-To: <E10D54F27C6AD11196EF00600812C5CF067E9D@CNENT>; from Tony Hernadez on Wed, Sep 06, 2000 at 09:16:20AM -0400

On Wed, Sep 06, 2000 at 09:16:20AM -0400, Tony Hernadez wrote:
> 
> I'm trying to run a mail command that will email me a message
> automatically... I'm not sure how to use the mail command without manually
> typing in the message and hitting CTRL+D. anyone done something like this ?

Something like this ? :

mail -s "The subject" root << END

this is the mail body
END

If you don't want a mail body, you can just do:
mail -s "The subject" root < /dev/null

--
Manuel Bouyer, LIP6, Universite Paris VI.           Manuel.Bouyer@lip6.fr
--