bug-coreutils
[Top][All Lists]
Advanced

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

Re: Date can dish it out, but not parse it back in


From: Eric Blake
Subject: Re: Date can dish it out, but not parse it back in
Date: Thu, 15 Jan 2009 18:14:52 -0700
User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.19) Gecko/20081209 Thunderbird/2.0.0.19 Mnenhy/0.7.5.666

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

According to address@hidden on 1/15/2009 9:50 AM:
> Date can dish it out, but not parse it back in, for other languages:

Thanks for the report.  However, this is a known design limitation - there
is no way to write a generic date parser that can parse all localized date
strings, so we can only parse non-localized strings (such as ISO formats)
and common C locale strings (which happen to be mostly English, sorry
about that).  But it would be nice if someone wanted to write a new option
to date, perhaps named --strptime, which calls strptime on the counterpart
date string given a formatting argument that looks similar to what the +
option passes on to strftime.  That way, the user can bypass the
generalized date parser in favor of a localized parser that understands
the user's preferred format.

- --
Don't work too hard, make some time for fun as well!

Eric Blake             address@hidden
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (Cygwin)
Comment: Public key at home.comcast.net/~ericblake/eblake.gpg
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iEYEARECAAYFAklv34wACgkQ84KuGfSFAYAYIgCgt07+/14OwsFV1Btilc1Mwk/s
mDYAniAZlCOdyRYEFyTFAbvZE6lA3npq
=rtEN
-----END PGP SIGNATURE-----




reply via email to

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