From owner-freebsd-questions Thu Feb 7 9: 8:29 2002 Delivered-To: freebsd-questions@freebsd.org Received: from bsduser.ca (CPE0080c6ee707f.cpe.net.cable.rogers.com [24.156.61.29]) by hub.freebsd.org (Postfix) with ESMTP id 6AA8437B41A for ; Thu, 7 Feb 2002 09:08:23 -0800 (PST) Received: from localhost (brett@localhost) by bsduser.ca (8.11.6/8.11.4) with ESMTP id g17H7lY07705 for ; Thu, 7 Feb 2002 12:07:47 -0500 (EST) (envelope-from brett@bsduser.ca) X-Authentication-Warning: bsduser.ca: brett owned process doing -bs Date: Thu, 7 Feb 2002 12:07:47 -0500 (EST) From: Brett Jackson To: questions@freebsd.org Subject: using `date` in a script Message-ID: <20020207120404.O7616-100000@bsduser.ca> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Hi, I am having difficulty passing a variable to date(8) and have it spit out the data in the date format. for example: birthday=19450104 >date -f ccyymmdd $birthday that is some ugly psuedocode, eh? Can I even do this? I have read the manpage to see how to format the current date, but am lost somewhere when trying the above. Thanks. Brett To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message