From owner-freebsd-questions@FreeBSD.ORG Tue Jul 8 11:58:24 2003 Return-Path: Delivered-To: freebsd-questions@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 02D8D37B401 for ; Tue, 8 Jul 2003 11:58:24 -0700 (PDT) Received: from falcon.mail.pas.earthlink.net (falcon.mail.pas.earthlink.net [207.217.120.74]) by mx1.FreeBSD.org (Postfix) with ESMTP id 3544943F75 for ; Tue, 8 Jul 2003 11:58:23 -0700 (PDT) (envelope-from parv_fm@mailsent.net) Received: from sdn-ap-029dcwashp0106.dialsprint.net ([65.177.104.106] helo=moo.holy.cow) by falcon.mail.pas.earthlink.net with esmtp (Exim 3.33 #1) id 19ZxfN-00037k-00; Tue, 08 Jul 2003 11:58:18 -0700 Received: by moo.holy.cow (Postfix, from userid 1001) id 9FB3DAFE9; Tue, 8 Jul 2003 15:01:20 -0400 (EDT) Date: Tue, 8 Jul 2003 15:01:20 -0400 From: parv To: Elliot Finley Message-ID: <20030708190120.GA55547@moo.holy.cow> Mail-Followup-To: Elliot Finley , freebsd-questions@FreeBSD.ORG References: <087c01c34560$7ed08e80$b4be0ed0@elliotdevelop> <20030708153145.GL87950@dan.emsphone.com> <5.2.0.9.2.20030708105106.01789890@mail.servplex.com> <09f301c3456b$4d029d20$b4be0ed0@elliotdevelop> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <09f301c3456b$4d029d20$b4be0ed0@elliotdevelop> cc: freebsd-questions@FreeBSD.ORG Subject: Re: No output from periodic X-BeenThere: freebsd-questions@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: User questions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 08 Jul 2003 18:58:24 -0000 in message <09f301c3456b$4d029d20$b4be0ed0@elliotdevelop>, wrote Elliot Finley thusly... > > I _want_ cron to email me when there _is_ output. But I _don't > want_ an email when there _isn't_ output. > > Anyone know how to accomplish this? In three (easy) steps... - Create a wrapper to be invoked by cron - In wrapper... - Execute the real command & save the output in a temporary file - Send e-mail only if file size is zero - Parv -- A programmer, budding Unix system administrator, and amateur photographer ISO employment... http://www103.pair.com/parv/work/