[Top][All Lists]

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

Re: Documentation of -atime, etc.

From: Andreas Metzler
Subject: Re: Documentation of -atime, etc.
Date: Sat, 1 Apr 2017 18:03:56 +0200
User-agent: NeoMutt/20170113 (1.7.2)

On 2017-04-01 "Dale R. Worley" <address@hidden> wrote:
> I was looking at an old sandbox I have that contains some partially-made
> changes to the documentation of -atime and related predicates.

> In find.texi is:

>     @deffn Test -atime [+|-]n
>     @deffnx Test -ctime [+|-]n
>     @deffnx Test -mtime [+|-]n
>     True if the file was last accessed (or its status changed, or it was
>     modified) (exactly/more than/less than) n'
>     @var{n}*24 hours ago.  The number of 24-hour periods since
>     the file's timestamp is always rounded down; therefore 0 means ``less
>     than 24 hours ago'', 1 means ``between 24 and 48 hours ago'', and so
>     forth.  Fractional values are supported but this only really makes
>     sense for the case where ranges (@address@hidden and @address@hidden)
>     are used.
>     @end deffn
> My question is the measning of "Fractional values are supported but this
> only really makes sense for the case where ranges (@address@hidden and
> @address@hidden) are used."  What is the "vlaue" that it is
> talking about, is it the "n" in the predicate or the "number of 24-hour
> periods since ..."?  The meaning seems to be the former (since the
> latter would contradict how the atime value is computed), but the usage
> of fractional "n" would not seem to be very useful, since a fractional
> "n" could always be replaced with an integral "n" with the same effect.

Try it out. ;-) Starting with a directory of files with mtime x hours
+ a couple of minutes ago (x=1..48) and named as such:

address@hidden:/tmp/FFF$ find -mtime -0.5 -type f | sort
address@hidden:/tmp/FFF$ find -mtime 0.5 -type f | sort
address@hidden:/tmp/FFF$ find -mtime -1 -type f | sort

I gues it is not a very useful feature and it really hard to describe
properly imho.

cu Andreas
`What a good friend you are to him, Dr. Maturin. His other friends are
so grateful to you.'
`I sew his ears on from time to time, sure'

reply via email to

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