Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-06 Thread Mark Martinec

On 2016-08-06 21:08, Julian Elischer wrote:

On 6/08/2016 11:09 PM, Benjamin Kaduk wrote:

On Sat, 6 Aug 2016, Baptiste Daroussin wrote:

On Sat, Aug 06, 2016 at 02:15:36PM +1000, Greg 'groggy' Lehey wrote:
On Friday,  5 August 2016 at 18:56:33 +0300, Andrey A. Chernov 
wrote:

On 05.08.2016 18:44, Mark Martinec wrote:

On 2016-08-05 17:23, Andrey Chernov wrote:

POSIX does say that the default format should be the same
as with "+%a %b %e %H:%M:%S %Z %Y".
It also says that %a and %b are locale's abbreviated names.
It is true for _POSIX_ locale only, as I already say. en_US.* is 
not

POSIX or C locale.

It still violates POLA.

I really do not think that it violates POLA fiven that the behaviour 
you are
expecting is still available in the default configurtion that is 
still POSIX.
Regardless, at a new major release is precisely when it is permissible 
to

break POLA.

switching from short form to long form is more than a POLA..  short
form has a specific fixed layout
and feeding a long form string into it will break things.


Set LC_TIME to C and then you are back on your behaviour (and this is 
the

default when you install FreeBSD).

locales should be seen as tzdata for exemple, they are a moving 
target
complicated to handle for every locale we do support: 78 for 
11.0-RELEASE and
193 if we do count the encoding variants. locales are updated very 
often (for
exemple cldr unicode make a new release of the data every 8 month or 
so)

As I understand it, your change will improve the maintainability of
locales in FreeBSD in the future, which justifies a POLA break at the
release boundary.
-Ben



$ LC_ALL=en_US.UTF-8 date

FreeBSD 11.0-BETA3 :
  Friday, August  5, 2016 at 03:20:25 PM CEST

FreeBSD 10.3-RELEASE-p6 :
  Fri Aug  5 15:15:11 CEST 2016

OSX version 10.9.5 :
  Fri Aug  5 14:57:14 CEST 2016

Fedora Linux 4.6.4-301.fc24.x86_64 :
  Fri Aug  5 15:10:40 CEST 2016

Debian 8.0 / Linux 4.4.16-v7+ :
  Fri Aug  5 15:25:49 CEST 2016

It's not just long vs. short forms of a name, it is also the order of 
fields,
their separators, and a 12/24h time form that is different from everyone 
else
and from what we used to have in 10.3.  Is it really worth being 
different?

I wonder how many ad-hoc scripts will break.

Although as Andrey Chernov correctly noted that the date(1) specs in
The Open Group Base Specifications Issue 7 IEEE Std 1003.1, 2013 Edition
( http://pubs.opengroup.org/onlinepubs/9699919799/utilities/date.html )
says that the default format applies to POSIX locale only:

  STDOUT
  When no formatting operand is specified, the output in the
  POSIX locale shall be equivalent to specifying:
date "+%a %b %e %H:%M:%S %Z %Y"

imo, unless there is a very good reason not to, the above default format
should be applicable to most locales, but at least to English spoken
locales. The explicit locale-dependency of %a, %b, and %Z conversion
specifications already takes care of most locale-specific 
idiosyncrasies.


  Mark


___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-06 Thread Julian Elischer

On 6/08/2016 11:09 PM, Benjamin Kaduk wrote:

On Sat, 6 Aug 2016, Baptiste Daroussin wrote:


On Sat, Aug 06, 2016 at 02:15:36PM +1000, Greg 'groggy' Lehey wrote:

On Friday,  5 August 2016 at 18:56:33 +0300, Andrey A. Chernov wrote:

On 05.08.2016 18:44, Mark Martinec wrote:

On 2016-08-05 17:23, Andrey Chernov wrote:

POSIX does say that the default format should be the same
as with "+%a %b %e %H:%M:%S %Z %Y".
It also says that %a and %b are locale's abbreviated names.

It is true for _POSIX_ locale only, as I already say. en_US.* is not
POSIX or C locale.

It still violates POLA.


I really do not think that it violates POLA fiven that the behaviour you are
expecting is still available in the default configurtion that is still POSIX.

Regardless, at a new major release is precisely when it is permissible to
break POLA.
switching from short form to long form is more than a POLA..  short 
form has a specific fixed layout

and feeding a long form string into it will break things.



Set LC_TIME to C and then you are back on your behaviour (and this is the
default when you install FreeBSD).

locales should be seen as tzdata for exemple, they are a moving target
complicated to handle for every locale we do support: 78 for 11.0-RELEASE and
193 if we do count the encoding variants. locales are updated very often (for
exemple cldr unicode make a new release of the data every 8 month or so)

As I understand it, your change will improve the maintainability of
locales in FreeBSD in the future, which justifies a POLA break at the
release boundary.

-Ben
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"



___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-06 Thread Benjamin Kaduk
On Sat, 6 Aug 2016, Baptiste Daroussin wrote:

> On Sat, Aug 06, 2016 at 02:15:36PM +1000, Greg 'groggy' Lehey wrote:
> > On Friday,  5 August 2016 at 18:56:33 +0300, Andrey A. Chernov wrote:
> > > On 05.08.2016 18:44, Mark Martinec wrote:
> > >> On 2016-08-05 17:23, Andrey Chernov wrote:
> > >>
> > >> POSIX does say that the default format should be the same
> > >> as with "+%a %b %e %H:%M:%S %Z %Y".
> > >> It also says that %a and %b are locale's abbreviated names.
> > >
> > > It is true for _POSIX_ locale only, as I already say. en_US.* is not
> > > POSIX or C locale.
> >
> > It still violates POLA.
> >
> I really do not think that it violates POLA fiven that the behaviour you are
> expecting is still available in the default configurtion that is still POSIX.

Regardless, at a new major release is precisely when it is permissible to
break POLA.

> Set LC_TIME to C and then you are back on your behaviour (and this is the
> default when you install FreeBSD).
>
> locales should be seen as tzdata for exemple, they are a moving target
> complicated to handle for every locale we do support: 78 for 11.0-RELEASE and
> 193 if we do count the encoding variants. locales are updated very often (for
> exemple cldr unicode make a new release of the data every 8 month or so)

As I understand it, your change will improve the maintainability of
locales in FreeBSD in the future, which justifies a POLA break at the
release boundary.

-Ben
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-06 Thread Baptiste Daroussin
On Sat, Aug 06, 2016 at 02:15:36PM +1000, Greg 'groggy' Lehey wrote:
> On Friday,  5 August 2016 at 18:56:33 +0300, Andrey A. Chernov wrote:
> > On 05.08.2016 18:44, Mark Martinec wrote:
> >> On 2016-08-05 17:23, Andrey Chernov wrote:
> >>> On 05.08.2016 17:47, Mark Martinec wrote:
>  [Bug 211598]
>    date(1) default format in en_EN locale breaks compatibility with 10.3
>  and violates POSIX
> 
>  https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211598
> >>>
> >>> It breaks compatibility but not violates POSIX. POSIX care of only its
> >>> own POSIX (or C) locale.
> >>
> >> POSIX does say that the default format should be the same
> >> as with "+%a %b %e %H:%M:%S %Z %Y".
> >> It also says that %a and %b are locale's abbreviated names.
> >
> > It is true for _POSIX_ locale only, as I already say. en_US.* is not
> > POSIX or C locale.
> 
> It still violates POLA.
> 
I really do not think that it violates POLA fiven that the behaviour you are
expecting is still available in the default configurtion that is still POSIX.

Set LC_TIME to C and then you are back on your behaviour (and this is the
default when you install FreeBSD).

locales should be seen as tzdata for exemple, they are a moving target
complicated to handle for every locale we do support: 78 for 11.0-RELEASE and
193 if we do count the encoding variants. locales are updated very often (for
exemple cldr unicode make a new release of the data every 8 month or so)

No locales defines the same date format and that was already the case before the
change we did

Now if people have strong arguments for a specific locale I'm inclined to add
some hacks in our tool that generates our locales to make sure we fix the
upstream data (http://cldr.unicode.org) we already committed some and I'm
planning to report upstream (cldr) all the issues we have faced to improve.

Best regards,
Bapt


signature.asc
Description: PGP signature


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-05 Thread Greg 'groggy' Lehey
On Friday,  5 August 2016 at 18:56:33 +0300, Andrey A. Chernov wrote:
> On 05.08.2016 18:44, Mark Martinec wrote:
>> On 2016-08-05 17:23, Andrey Chernov wrote:
>>> On 05.08.2016 17:47, Mark Martinec wrote:
 [Bug 211598]
   date(1) default format in en_EN locale breaks compatibility with 10.3
 and violates POSIX

 https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211598
>>>
>>> It breaks compatibility but not violates POSIX. POSIX care of only its
>>> own POSIX (or C) locale.
>>
>> POSIX does say that the default format should be the same
>> as with "+%a %b %e %H:%M:%S %Z %Y".
>> It also says that %a and %b are locale's abbreviated names.
>
> It is true for _POSIX_ locale only, as I already say. en_US.* is not
> POSIX or C locale.

It still violates POLA.

Greg
--
Sent from my desktop computer.
Finger g...@freebsd.org for PGP public key.
See complete headers for address and phone numbers.
This message is digitally signed.  If your Microsoft mail program
reports problems, please read http://lemis.com/broken-MUA


signature.asc
Description: PGP signature


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-05 Thread Andrey Chernov
On 05.08.2016 18:44, Mark Martinec wrote:
> On 2016-08-05 17:23, Andrey Chernov wrote:
>> On 05.08.2016 17:47, Mark Martinec wrote:
>>> [Bug 211598]
>>>   date(1) default format in en_EN locale breaks compatibility with 10.3
>>> and violates POSIX
>>>
>>> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211598
>>
>> It breaks compatibility but not violates POSIX. POSIX care of only its
>> own POSIX (or C) locale.
> 
> POSIX does say that the default format should be the same
> as with "+%a %b %e %H:%M:%S %Z %Y".
> It also says that %a and %b are locale's abbreviated names.

It is true for _POSIX_ locale only, as I already say. en_US.* is not
POSIX or C locale.

> It may not say what an abbreviated name really looks like
> in a particular locale, but it does distinguish between
> full and abbreviated names.

It says nothing about other locales. Current format comes from CLDR, ask
bapt@


___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-05 Thread Mark Martinec

On 2016-08-05 17:23, Andrey Chernov wrote:

On 05.08.2016 17:47, Mark Martinec wrote:

[Bug 211598]
  date(1) default format in en_EN locale breaks compatibility with 
10.3

and violates POSIX

https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211598


It breaks compatibility but not violates POSIX. POSIX care of only its
own POSIX (or C) locale.


POSIX does say that the default format should be the same
as with "+%a %b %e %H:%M:%S %Z %Y".
It also says that %a and %b are locale's abbreviated names.

It may not say what an abbreviated name really looks like
in a particular locale, but it does distinguish between
full and abbreviated names.

  Mark
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-05 Thread Andrey Chernov
On 05.08.2016 17:47, Mark Martinec wrote:
> [Bug 211598]
>   date(1) default format in en_EN locale breaks compatibility with 10.3
> and violates POSIX
> 
> https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211598

It breaks compatibility but not violates POSIX. POSIX care of only its
own POSIX (or C) locale.


___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"


Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-05 Thread Mark Martinec

On 2016-08-05 07:00, Julian Elischer wrote:

On 5/08/2016 5:44 AM, Mark Martinec wrote:

Should I open a bug report, or has the problem been noted?

it's not clear without reading the standard whether the bug is in the
old or new version.
have you tried other systems? In particular I'd check OSX



Did some research, opened a PR against 11.0-BETA3:

[Bug 211598]
  date(1) default format in en_EN locale breaks compatibility with 10.3 
and violates POSIX


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=211598


  Mark




On 2016-08-05 07:00, Julian Elischer wrote:
[...]

sh-3.2$ export LC_CTYPE="en_US.UTF-8"
sh-3.2$ export LC_TIME="en_US.UTF-8"
sh-3.2$ export LC_ALL="en_US.UTF-8"
sh-3.2$ export LC_NUMERIC="en_US.UTF-8"
sh-3.2$ date
Fri Aug  5 12:57:47 AWST 2016

if it IS a bug then yes, file a report with full reproduction steps.




On 2016-08-04 04:32, Julian Elischer wrote:

On 4/08/2016 7:24 AM, Mark Martinec wrote:

Is it normal/expected/documented that the date(1) command in 11.0
now produces a timestamp in substantially different format
in an "en_US.UTF-8" locale (long names, commas, 12 vs. 24h hour 
time):


  Thursday, August  4, 2016 at 12:50:43 AM CEST
vs:
  Thu Aug  4 00:52:29 CEST 2016


one of those is a bug.  the formats are defined in posix I believe.



Setting LC_TIME does not help:

  $LC_TIME="C" date
  Thursday, August  4, 2016 at 01:13:37 AM CEST

although LC_ALL="C" _does_ help.


This is funny too, especially regarding commas:
  $ LC_ALL="en_GB.UTF-8" date
  Thursday  4 August 2016 at 01:16:45 CEST
  $ LC_ALL="en_US.UTF-8" date
  Thursday, August  4, 2016 at 01:16:54 AM CEST


The date(1) man page states:
  The date utility is expected to be compatible with IEEE Std 1003.2
  (“POSIX.2”).
What does POSIX.2 say about date(1) following a locale?



==
11.0-BETA3:

$ date
Thursday, August  4, 2016 at 12:50:43 AM CEST

$ uname -a
FreeBSD xxx.ijs.si 11.0-BETA3 FreeBSD 11.0-BETA3 #0 r303469: Fri Jul 
29 02:27:28 UTC 2016 
r...@releng2.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8

==
10.3-RELEASE-p6 :

$ date
Thu Aug  4 00:52:29 CEST 2016

$ freebsd-version
10.3-RELEASE-p6

$ uname -a
FreeBSD yyy.ijs.si 10.3-RELEASE-p4 FreeBSD 10.3-RELEASE-p4 #0: Sat 
May 28 12:23:44 UTC 2016 
r...@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC 
amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8



  Mark

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-04 Thread Julian Elischer

On 5/08/2016 5:44 AM, Mark Martinec wrote:

Should I open a bug report, or has the problem been noted?
it's not clear without reading the standard whether the bug is in the 
old or new version.

have you tried other systems? In particular I'd check OSX

sh-3.2$ export LC_CTYPE="en_US.UTF-8"
sh-3.2$ export LC_TIME="en_US.UTF-8"
sh-3.2$ export LC_ALL="en_US.UTF-8"
sh-3.2$ export LC_NUMERIC="en_US.UTF-8"
sh-3.2$ date
Fri Aug  5 12:57:47 AWST 2016

if it IS a bug then yes, file a report with full reproduction steps.



  Mark


On 2016-08-04 04:32, Julian Elischer wrote:

On 4/08/2016 7:24 AM, Mark Martinec wrote:

Is it normal/expected/documented that the date(1) command in 11.0
now produces a timestamp in substantially different format
in an "en_US.UTF-8" locale (long names, commas, 12 vs. 24h hour 
time):


  Thursday, August  4, 2016 at 12:50:43 AM CEST
vs:
  Thu Aug  4 00:52:29 CEST 2016


one of those is a bug.  the formats are defined in posix I believe.



Setting LC_TIME does not help:

  $LC_TIME="C" date
  Thursday, August  4, 2016 at 01:13:37 AM CEST

although LC_ALL="C" _does_ help.


This is funny too, especially regarding commas:
  $ LC_ALL="en_GB.UTF-8" date
  Thursday  4 August 2016 at 01:16:45 CEST
  $ LC_ALL="en_US.UTF-8" date
  Thursday, August  4, 2016 at 01:16:54 AM CEST


The date(1) man page states:
  The date utility is expected to be compatible with IEEE Std 1003.2
  (“POSIX.2”).
What does POSIX.2 say about date(1) following a locale?



==
11.0-BETA3:

$ date
Thursday, August  4, 2016 at 12:50:43 AM CEST

$ uname -a
FreeBSD xxx.ijs.si 11.0-BETA3 FreeBSD 11.0-BETA3 #0 r303469: Fri 
Jul 29 02:27:28 UTC 2016 
r...@releng2.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8

==
10.3-RELEASE-p6 :

$ date
Thu Aug  4 00:52:29 CEST 2016

$ freebsd-version
10.3-RELEASE-p6

$ uname -a
FreeBSD yyy.ijs.si 10.3-RELEASE-p4 FreeBSD 10.3-RELEASE-p4 #0: Sat 
May 28 12:23:44 UTC 2016 
r...@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8



  Mark

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to 
"freebsd-current-unsubscr...@freebsd.org"





___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-04 Thread Mark Martinec

Should I open a bug report, or has the problem been noted?

  Mark


On 2016-08-04 04:32, Julian Elischer wrote:

On 4/08/2016 7:24 AM, Mark Martinec wrote:

Is it normal/expected/documented that the date(1) command in 11.0
now produces a timestamp in substantially different format
in an "en_US.UTF-8" locale (long names, commas, 12 vs. 24h hour time):

  Thursday, August  4, 2016 at 12:50:43 AM CEST
vs:
  Thu Aug  4 00:52:29 CEST 2016


one of those is a bug.  the formats are defined in posix I believe.



Setting LC_TIME does not help:

  $ LC_TIME="C" date
  Thursday, August  4, 2016 at 01:13:37 AM CEST

although LC_ALL="C" _does_ help.


This is funny too, especially regarding commas:
  $ LC_ALL="en_GB.UTF-8" date
  Thursday  4 August 2016 at 01:16:45 CEST
  $ LC_ALL="en_US.UTF-8" date
  Thursday, August  4, 2016 at 01:16:54 AM CEST


The date(1) man page states:
  The date utility is expected to be compatible with IEEE Std 1003.2
  (“POSIX.2”).
What does POSIX.2 say about date(1) following a locale?



==
11.0-BETA3:

$ date
Thursday, August  4, 2016 at 12:50:43 AM CEST

$ uname -a
FreeBSD xxx.ijs.si 11.0-BETA3 FreeBSD 11.0-BETA3 #0 r303469: Fri Jul 
29 02:27:28 UTC 2016 
r...@releng2.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC  amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8

==
10.3-RELEASE-p6 :

$ date
Thu Aug  4 00:52:29 CEST 2016

$ freebsd-version
10.3-RELEASE-p6

$ uname -a
FreeBSD yyy.ijs.si 10.3-RELEASE-p4 FreeBSD 10.3-RELEASE-p4 #0: Sat May 
28 12:23:44 UTC 2016 
r...@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8



  Mark

___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"

Re: date(1) default format changed between 10.3 and 11.0-BETA3

2016-08-03 Thread Julian Elischer

On 4/08/2016 7:24 AM, Mark Martinec wrote:

Is it normal/expected/documented that the date(1) command in 11.0
now produces a timestamp in substantially different format
in an "en_US.UTF-8" locale (long names, commas, 12 vs. 24h hour time):

  Thursday, August  4, 2016 at 12:50:43 AM CEST
vs:
  Thu Aug  4 00:52:29 CEST 2016


one of those is a bug.  the formats are defined in posix I believe.



Setting LC_TIME does not help:

  $ LC_TIME="C" date
  Thursday, August  4, 2016 at 01:13:37 AM CEST

although LC_ALL="C" _does_ help.


This is funny too, especially regarding commas:
  $ LC_ALL="en_GB.UTF-8" date
  Thursday  4 August 2016 at 01:16:45 CEST
  $ LC_ALL="en_US.UTF-8" date
  Thursday, August  4, 2016 at 01:16:54 AM CEST


The date(1) man page states:
  The date utility is expected to be compatible with IEEE Std 1003.2
  (“POSIX.2”).
What does POSIX.2 say about date(1) following a locale?



==
11.0-BETA3:

$ date
Thursday, August  4, 2016 at 12:50:43 AM CEST

$ uname -a
FreeBSD xxx.ijs.si 11.0-BETA3 FreeBSD 11.0-BETA3 #0 r303469: Fri Jul 
29 02:27:28 UTC 2016 
r...@releng2.nyi.freebsd.org:/usr/obj/usr/src/sys/GENERIC  amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8

==
10.3-RELEASE-p6 :

$ date
Thu Aug  4 00:52:29 CEST 2016

$ freebsd-version
10.3-RELEASE-p6

$ uname -a
FreeBSD yyy.ijs.si 10.3-RELEASE-p4 FreeBSD 10.3-RELEASE-p4 #0: Sat 
May 28 12:23:44 UTC 2016 
r...@amd64-builder.daemonology.net:/usr/obj/usr/src/sys/GENERIC amd64


$ locale
LANG=
LC_CTYPE="en_US.UTF-8"
LC_COLLATE="en_US.UTF-8"
LC_TIME="en_US.UTF-8"
LC_NUMERIC="en_US.UTF-8"
LC_MONETARY="en_US.UTF-8"
LC_MESSAGES="en_US.UTF-8"
LC_ALL=en_US.UTF-8



  Mark
___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to 
"freebsd-current-unsubscr...@freebsd.org"





___
freebsd-current@freebsd.org mailing list
https://lists.freebsd.org/mailman/listinfo/freebsd-current
To unsubscribe, send any mail to "freebsd-current-unsubscr...@freebsd.org"