The find(1) page shows:
find [-H | -L | -P] [-EXdsx] [-f path] path ... [expression]
find [-H | -L | -P] [-EXdsx] -f path [path ...] [expression]
What does -f mean?
I would have thought it's trivial. Just give the path for the start of the search. It doesn't seem to work that way.
$ find -f /tmp -newer /boot/kernel/kernel
I get an error "find: illegal option -- n", presumably from the -newer expression.
Historically, I would use:
$ find /tmp -newer /boot/kernel/kernel
FWIW, I firmly believe that if a person fully understands find, they have achieved guru status. In other news, I recently learned why its dangerous to use find with -exec rm {}. I'm surprised I dodged that bullet for the last 25 years. People talk about rm -rf being dangerous. Pikers!
find [-H | -L | -P] [-EXdsx] [-f path] path ... [expression]
find [-H | -L | -P] [-EXdsx] -f path [path ...] [expression]
What does -f mean?
I would have thought it's trivial. Just give the path for the start of the search. It doesn't seem to work that way.
$ find -f /tmp -newer /boot/kernel/kernel
I get an error "find: illegal option -- n", presumably from the -newer expression.
Historically, I would use:
$ find /tmp -newer /boot/kernel/kernel
FWIW, I firmly believe that if a person fully understands find, they have achieved guru status. In other news, I recently learned why its dangerous to use find with -exec rm {}. I'm surprised I dodged that bullet for the last 25 years. People talk about rm -rf being dangerous. Pikers!
Last edited: