bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Bug in GNU date ??


From: MUTTON, PETER
Subject: Re: Bug in GNU date ??
Date: Tue, 06 Apr 2004 22:05:04 -0400

Hi Paul,

You are right, I was thinking of it checking the timezone db to see
what timezone I'm in when I'm actually specifying it in the date
itself.....

Your 2nd suggestion is excellent, I didn't think of doing it that
way.....

Duh !!  lateral thinking

Thanks

Paul Eggert wrote:
> 
> "MUTTON, PETER" <address@hidden> writes:
> 
> >     #> /usr/local/bin/date -u -d "Sat Apr  3 16:42:28 EDT 2004"
> >     Sat Apr  3 20:42:28 UTC 2004
> >
> >                ^^ should be 21 as we moved to Daylight Saving time
> >                   on Apr 4
> 
> I don't see any bug there.  The -d operand specifies EDT, so GNU date
> assumes that you meant Eastern Daylight Time.
> 
> Here's how to get the behavior that you prefer:
> 
> $ /usr/local/bin/date -u -d "Sat Apr  3 16:42:28 EST 2004"
> Sat Apr  3 21:42:28 UTC 2004
> 
> Or better yet, since alphabetic time zone abbreviations aren't
> standardized:
> 
> $ /usr/local/bin/date -u -d "Sat Apr  3 16:42:28 -0500 2004"
> Sat Apr  3 21:42:28 UTC 2004

-- 
Peter Mutton
SysAdmin
Bell Canada - Operations Technical & Systems Support
              Soutien technique et systèmes aux opérations
Tel:  613-832-0942





reply via email to

[Prev in Thread] Current Thread [Next in Thread]