From owner-freebsd-hackers Sun Sep 16 20:22:12 2001 Delivered-To: freebsd-hackers@freebsd.org Received: from virtual-voodoo.com (bdsl.66.12.217.106.gte.net [66.12.217.106]) by hub.freebsd.org (Postfix) with ESMTP id 0B5BA37B406 for ; Sun, 16 Sep 2001 20:22:01 -0700 (PDT) Received: (from steve@localhost) by virtual-voodoo.com (8.11.6/8.11.5) id f8H3HTR15682; Sun, 16 Sep 2001 22:17:29 -0500 (EST) (envelope-from steve) Date: Sun, 16 Sep 2001 22:17:29 -0500 From: Steve Ames To: Greg Black Cc: Eugene Grosbein , Tim Allshorn , freebsd-hackers@FreeBSD.ORG Subject: Re: Cron pickle Message-ID: <20010916221729.A25329@virtual-voodoo.com> References: <20010917105932.A5338@svzserv.kemerovo.su> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.2.5i In-Reply-To: ; from gjb@gbch.net on Mon, Sep 17, 2001 at 01:07:59PM +1000 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG On Mon, Sep 17, 2001 at 01:07:59PM +1000, Greg Black wrote: > Eugene Grosbein wrote: > | This can be done with cron with single entry and small overhead. > | Run whis script at last minute of every day (or every 28-31): > | > | #!/bin/sh > | > | tomorrow=`date -v+1d %d` > | if [ $tomorroq -ne "01" ]; then > | exit # if tomorrow is not begin of month, do nothing > | fi > | > | # do work now > > Sure: > > $ date -v+1d %d date -v+1d +%d -Steve To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message