Re: It it now a leap year?

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

 



Andrew Parker:
>> For bash the following will display 061 if its currently a leap year,
>> 060 otherwise
>> 
>> date -d "$(date +%Y)/03/01" +%j

Kevin J. Cummings:
> It doesn't work with dates after 2037/03/01 ....

Leaving you with thirty years to develop a solution, or spend a few
minutes pondering whether to bother...  ;-)

But seriously, although some might think you don't need to worry about
such things, there are programs that will need to do some work using a
date from the future.  The matter is more urgent than immediately
obvious.

-- 
(This box runs FC5, my others run FC4 & FC6, in case that's
 important to the thread.)

Don't send private replies to my address, the mailbox is ignored.
I read messages from the public lists.


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux