bug-coreutils
[Top][All Lists]
Advanced

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

Re: Bug#474436: coreutils: "ls --time-style=locale" no longer works


From: Bo Borgerson
Subject: Re: Bug#474436: coreutils: "ls --time-style=locale" no longer works
Date: Sun, 6 Apr 2008 11:55:03 -0400

Hi,

This can affect invocations of `ls' that don't include an explicit
`--time-style=locale', as well, since that is now the default (in
absence of a TIME_STYLE environment variable).

The only case I can see in the head revision of `ls.c' where the
default English time-style is used is when there is no `hard locale'
in effect for time (LC_TIME=C or POSIX).

In case it might be desirable to have the time-style default to N_("%b
%e  %Y") and  N_("%b %e %H:%M") (the `defaults') rather than
'posix-long-iso' ("%Y-%m-%d %H:%M" in all cases) for locales that
begin with 'en_', I've included a small patch that provides this
behavior.

----
$ LC_ALL=zh_CN.UTF-8 src/ls -l TODO
-rw-r--r-- 1 bo bo 6908 2008-03-31 21:09 TODO

$ LC_ALL=en_US.UTF-8 src/ls -l TODO
-rw-r--r-- 1 bo bo 6908 Mar 31 21:09 TODO

$ LC_ALL=C src/ls -l TODO
-rw-r--r-- 1 bo bo 6908 Mar 31 21:09 TODO
----

Thanks,

Bo

Attachment: ls-time-format.diff
Description: Text Data


reply via email to

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