coreutils
[Top][All Lists]
Advanced

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

Re: [coreutils] stat: reverting recent %X %Y %Z change


From: Pádraig Brady
Subject: Re: [coreutils] stat: reverting recent %X %Y %Z change
Date: Sat, 23 Oct 2010 00:37:23 +0100
User-agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.1.8) Gecko/20100227 Thunderbird/3.0.3

On 22/10/10 18:43, Jim Meyering wrote:
> Part of reverting this change:
> 
>     stat now outputs the full sub-second resolution for the atime,
>     mtime, and ctime values since the Epoch, when using the %X, %Y, and
>     %Z directives of the --format option.  This matches the fact that
>     %x, %y, and %z were already doing so for the human-readable variant.
> 
> means considering whether to do the same sort of thing with the
> newly-added %W (birth time/crtime).  Note that %W currently expands to "-"
> on systems with no support (e.g., linux).
> 
> I don't particularly like the idea of making stat do this:
> 
>     $ src/stat -c %W.%:W .
>     -.-
> 
> Rather, I have a slight preference to make it do this:
> 
>     $ src/stat -c %W.%:W .
>     0.000000000

I prefer that as it would mean less special
cases in code that uses the output.

> In any case, I think %w should still expand to "-".
> 
> The alternative is to leave %W separate, with no %:W variant.
> I.e., %W would continue to print floating point seconds.
> In that case, it would be inconsistent with %X, %Y and %Z.

I don't like that.

cheers,
Pádraig.



reply via email to

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