[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: bug in date command
From: |
Andreas Schwab |
Subject: |
Re: bug in date command |
Date: |
Fri, 14 May 2004 18:05:24 +0200 |
User-agent: |
Gnus/5.110002 (No Gnus v0.2) Emacs/21.3.50 (gnu/linux) |
Bauke Jan Douma <address@hidden> writes:
> On Fri, May 14, 2004 at 11:27:53AM +0200, Andreas Schwab wrote:
>> Bauke Jan Douma <address@hidden> writes:
>>
>> > On Fri, May 14, 2004 at 12:51:20AM +0200, Andreas Schwab wrote:
>> >> "duncan brown" <address@hidden> writes:
>> >>
>> >> > date +%C reports the 20th century, but we've been in the 21st since jan
>> >> > 01, 00:00:00
>> >>
>> >> %C century (year divided by 100 and truncated to an integer) [00-99]
>> >
>> > Surely this must be a Y2K-ism in the standard, no?
>>
>> Why?
>>
>> $ date +%C%y
>> 2004
>
> I am sorry, I answered under the assumption that you wrote
> 'truncated to the closest integer'.
>
> Still, there is discrepancy in one common meaning of the word
> 'century' and the meaning it has here, as the original
> poster noted. Here it apparently means something like 'the
> century part of the full year-number.'
The text is nearly identical to the one in the POSIX standard.
Andreas.
--
Andreas Schwab, SuSE Labs, address@hidden
SuSE Linux AG, Maxfeldstraße 5, 90409 Nürnberg, Germany
Key fingerprint = 58CA 54C7 6D53 942B 1756 01D3 44D5 214B 8276 4ED5
"And now for something completely different."