From owner-freebsd-hackers Thu Jul 31 22:26:37 1997 Return-Path: Received: (from root@localhost) by hub.freebsd.org (8.8.5/8.8.5) id WAA29201 for hackers-outgoing; Thu, 31 Jul 1997 22:26:37 -0700 (PDT) Received: from genesis.atrad.adelaide.edu.au (genesis.atrad.adelaide.edu.au [129.127.96.120]) by hub.freebsd.org (8.8.5/8.8.5) with ESMTP id WAA29192 for ; Thu, 31 Jul 1997 22:26:31 -0700 (PDT) Received: from freebie.lemis.com (gregl1.lnk.telstra.net [139.130.136.133]) by genesis.atrad.adelaide.edu.au (8.8.5/8.7.3) with ESMTP id OAA03568; Fri, 1 Aug 1997 14:56:23 +0930 (CST) From: Greg Lehey Received: (grog@localhost) by freebie.lemis.com (8.8.6/8.6.12) id OAA08967; Fri, 1 Aug 1997 14:56:21 +0930 (CST) Message-Id: <199708010526.OAA08967@freebie.lemis.com> Subject: Re: date(1) In-Reply-To: <28422.870412711@time.cdrom.com> from "Jordan K. Hubbard" at "Jul 31, 97 10:18:31 pm" To: jkh@time.cdrom.com (Jordan K. Hubbard) Date: Fri, 1 Aug 1997 14:56:21 +0930 (CST) Cc: grog@lemis.com, brian@awfulhak.org, hackers@FreeBSD.ORG Organisation: LEMIS, PO Box 460, Echunga SA 5153, Australia Phone: +61-8-8388-8250 Fax: +61-8-8388-8250 Mobile: +61-41-739-7062 WWW-Home-Page: http://www.lemis.com/~grog X-Mailer: ELM [version 2.4ME+ PL32 (25)] MIME-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Sender: owner-freebsd-hackers@FreeBSD.ORG X-Loop: FreeBSD.org Precedence: bulk Jordan K. Hubbard writes: >> Now here's an enhancement that I *would* like to see: specify a >> timezone file to use. Something like: >> >> $ date -z /usr/share/zoneinfo/Asia/Tokyo >> >> to give you the current time in Tokyo. > > Blah. What's wrong with: > > jkh@time-> TZ=Asia/Tokyo date > Fri Aug 1 14:18:15 JST 1997 > > ? The documentation's inadequate. Sure, it points to environ(7), but since TZ is almost never used in BSD, there's a tendency to think it'll be like a System V TZ, which is completely different. How about adding: --- /usr/share/man/man1/date.1.orig Fri Aug 1 04:13:12 1997 +++ /usr/share/man/man1/date.1 Fri Aug 1 14:54:38 1997 @@ -171,6 +171,11 @@ .Bl -tag -width Ds .It Ev TZ The timezone to use when displaying dates. +The normal format is a pathname relative to +.Dq Pa /usr/share/zoneinfo . +For example, the command +.Dq env TZ=America/Los_Angeles date +displays the current time in California. See .Xr environ 7 for more information.