From: "Mr Mayes" <dad@mayesie.freeserve.co.uk>
Subject: Re: Date Calculations
Date: 1998/10/19 [thread overview]
Message-ID: <70g3ro$n8s$1@newsreader1.core.theplanet.net> (raw)
In-Reply-To: 6vju3c$emk$1@newsflash.concordia.ca
>>I want to be able to set a variable to the current date minus 7. I'm using
>>date +"%d-%b-%y"to return the current date and I want to be able to return
>>the same format for 1 week ago.
>
It should be simple enough using the TZ environment variable.
TZ=GMT168 date +"+"%d-%b-%y" ought to do the job.
Substitute your favourite time zone for GMT.
Cheers
Rich
next prev parent reply other threads:[~1998-10-19 4:00 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
1998-10-02 4:00 Date Calculations lloydy1090
1998-10-09 4:00 ` Steven Winikoff
1998-10-09 4:00 ` Chris Weber
1998-10-19 4:00 ` Mr Mayes [this message]
1998-10-29 5:00 ` Bob Vickers
1998-11-06 5:00 ` Richard Mayes
1998-11-13 5:00 ` Bob Vickers
-- strict thread matches above, loose matches on Subject: below --
1996-05-14 4:00 Robert Reed
read-only archive
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox