From owner-freebsd-questions@FreeBSD.ORG Tue Sep 30 11:10:32 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 5D55D16A4B3 for ; Tue, 30 Sep 2003 11:10:32 -0700 (PDT) Received: from wopr.caltech.edu (wopr.caltech.edu [131.215.103.10]) by mx1.FreeBSD.org (Postfix) with ESMTP id 981D943FF5 for ; Tue, 30 Sep 2003 11:10:31 -0700 (PDT) (envelope-from mph@wopr.caltech.edu) Received: from wopr.caltech.edu (localhost.caltech.edu [127.0.0.1]) by wopr.caltech.edu (8.12.9/8.12.9) with ESMTP id h8UIAUga002896; Tue, 30 Sep 2003 11:10:30 -0700 (PDT) (envelope-from mph@wopr.caltech.edu) Received: (from mph@localhost) by wopr.caltech.edu (8.12.9/8.12.9/Submit) id h8UIAU0m002895; Tue, 30 Sep 2003 11:10:30 -0700 (PDT) Date: Tue, 30 Sep 2003 11:10:29 -0700 From: Matthew Hunt To: Odhiambo Washington , Free BSD Questions list Message-ID: <20030930181029.GA2738@wopr.caltech.edu> References: <20030930164957.GL59342@ns2.wananchi.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20030930164957.GL59342@ns2.wananchi.com> User-Agent: Mutt/1.5.1i Subject: Re: complex crontab query 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, 30 Sep 2003 18:10:32 -0000 Here are untested examples that I think should work. They run the job at 3:00 am (the first two fields). On Tue, Sep 30, 2003 at 07:49:57PM +0300, Odhiambo Washington wrote: > 1. 3rd day and 28th day of each month (seems easy) 0 3 3,28 * * mycommand > 2. Every first Thursday of the month 0 3 1-7 * * [ `date +%a` = Thu ] && mycommand -- Matthew Hunt * Science rules. http://www.pobox.com/~mph/ *