Re: Excluding future-dated files in 'find' on Cygwin

Andreas Metzler <[email protected]>
Newsgroups gmane.comp.gnu.findutils.bugs
Message-ID <[email protected]>
On 2023-10-20 Backwoods BC <[email protected]> wrote:
> On Fri, Oct 13, 2023 at 7:55 AM Andreas Metzler <[email protected]> wrote:
> > On 2023-10-13 Backwoods BC <[email protected]> wrote:
> > [...]
[...]
> TFM says:
> -atime n
> File was last accessed less than, more than or exactly n*24 hours ago.
> When find figures out how many 24-hour periods ago the file was last
> accessed, any fractional part is ignored, so to match -atime +1, a
> file has to have been accessed at least two days ago.

> I interpret this to mean that -mtime +0 -mtimt -1 means greater than
> zero hours ago AND less than 47:59:59 ago -- which finds nothing.

Hello,

This interpretation disregards "any fractional part is ignored."

-mtime +0 means that *after* *throwing* *away* *any* *fractional* *part*
(less than a 24:00:00) the time difference is still greater than 0 day,
i.e.  modified at least 24 hours ago.

Same for -mtime -1, which therefore means modified less than 24 hours ago.

Therefore, no overlap, no matches.

cu Andreas
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.