[Toybox] [landley/toybox] find -cmin -amin -mmin (#58)

Rob Landley rob at landley.net
Tue Dec 20 14:23:16 PST 2016


On 12/11/2016 06:29 PM, brian-leidos wrote:
> My use case has to do with forensics. After I install or run an app,
> wanting to find what's changed in the file system. find -cmin/amin/mmin
> is supported in Linux, macOS, though I'm not sure about Posix.
> Obviously, I could put a file and use the -newer option, but as a
> forensic standpoint, I'd rather not be introducing new files like that.
> Make sense?

I.E. "this is an option I personally use". Got it.

Huh, digging into it, -atime isn't seconds, it's _days_. There should
probably be -asec and friends too, but I'm reluctant to add new API out
of the blue. (And if I was going to do that I'd want to add a suffix to
-atime to specify seconds, minutes, or hours.)

Ok, how about this: I'll implement the existing -amin/cmin/mmin api but
not add it to the help text, and _also_ implement an "-atime 3m" suffix
to specify units (years days hours minutes). Then _document_ the second
one, but accept both syntaxes for compatibility, and have "-atime" vs
"-amin" change which default units to use.

Sound reasonable?

Rob



More information about the Toybox mailing list